Ruby on Rails - adding a simple react component to our app in ruby on rails - ruby on rails tutorial - rails guides - rails tutorial - ruby rails
Step1
- Add the hyperloop gem to our rails (4.0 - 5.1) Gemfile
Step2
- bundle install
step3
- Hyperloop manifest to the application.js file:
Step4
- Create our react components, and place them in the hyperloop/components directory
Step5
- Components act just like views.
- They are "mounted" using the render_component method in a controller: