Integration of React + Webpack + Rails + rails/webpacker including server-side rendering of React, enabling a better developer experience and faster client performance.
rails/webpacker
, shakapacker
.These are the docs for React on Rails 13. To see the older docs: v12 and v11.
React on Rails integrates Rails with (server rendering of) React.
This project is maintained by ShakaCode.
ShakaCode focuses on helping Ruby on Rails teams better use React and Webpack. We can upgrade your project and improve your development and customer experiences, allowing you to focus on building new features or fixing bugs instead.
For an overview of working with us, see our Client Engagement Model article and how we bill for time.
We also specialize in helping development teams lower infrastructure and CI costs. Check out our project Control Plane Flow, which can allow you to get the ease of Heroku with the power of Kubernetes and big cost savings.
If you think ShakaCode can help your project, click here to book a call with Justin Gordon, the creator of React on Rails.
Are you interested in optimizing your webpack setup for React on Rails, including code splitting with react-router and loadable-components with server-side rendering for SEO and hot-reloading for developers?
We did this for Popmenu, lowering Heroku costs 20-25% while getting a 73% decrease in average response times. Several years later, Popmenu serves tens of millions of SSR requests daily with React on Rails Pro.
If you’re interested, read more about React on Rails Pro and book a call.
See the documentation at shakacode.com/react-on-rails/docs.
To provide a high-performance framework for integrating Ruby on Rails with React, especially regarding React Server-Side Rendering for better SEO and improved performance.
Given that shakacode/shakapacker
gem already provides basic React integration, why would you use “React on Rails”?
javascript_pack_tags
and stylesheet_pack_tags
on your layouts based on what’s shown. “It just works!”See Rails/Webpacker React Integration Options for comparisons to other gems.
spec/dummy
, which demonstrates several uses of react_on_rails
, will soon be available on Control Plane through this linkRequires creating a free account.
Ruby on Rails >=5, rails/webpacker >= 4.2 or shakapacker > 6, Ruby >= 3.0.0
Bug reports and pull requests are welcome. To get started, see Contributing and the list of help wanted issues.
ShakaCode is hiring passionate software engineers to work on our projects, including HiChee!
The gem is available as open source under the terms of the MIT License.
The following companies support our open-source projects, and ShakaCode uses their products!