React Ruby Build Guide
This Ruby on Rails app uses React to pull data from Zesty.io endpoints, showing the simplicity of using the platform. The example consumes the Homepage and Menu endpoints from Zesty.io.
Getting Started with the Example App#
Let's start by cloning the example app
Now, let's install and run the app (Make sure you have Ruby version 2.4.4 or higher. To manage your versions and to keep your system Ruby separate, we recommend using
Understanding the Example Project
In this project, we are using two custom endpoints,
/-/custom/menulist.json. To retrieve this data, we've put a React component inside our Ruby app. This streamlines the process significantly, since now we can simply use the same code as that from our Remote React App Guide.
componentDidMount, we're able to fetch our JSON and render it accordingly. After we load it in, it's just a matter of parsing a JS Object.
Connect with Content Experts
Book a free 15-minute consultation with a content expert. Discuss your application, pain points and requirements. Understand how Zesty's lower total cost of ownership, features, functionality can elevate your business by creating extraordinary digital experiences.
G2 MOMENTUM LEADER