Add react-rails to your Gemfile:
gem 'react-rails'
And install:
bundle install
Next, run the installation script:
rails g react:install
This will:
create a components.js manifest file and a app/assets/javascripts/components/ directory, where you will put your components place the following in your application.js:
//= require react
//= require react_ujs
//= require components