A couple of months ago, after a long hacking night, Juan and I were discussing front-end library options for our upcoming app project over Slack. Overloaded with client work, we were looking for a library we can learn in a short time.
Then we tried React.js, even though the official React documentation is not as great as Rails’ documentation, after a couple of hours of hacking, React felt very simple to learn and in a week or so we decided to re-build all our apps with React.
Webpacker in Rails coexists with the asset pipeline. This structure provides a powerful separation of front-end from the back-end. While benefiting all great features comes out of the box with Rails, front-end development gets done much faster with ES6 + JSX combination and React flow. The code becomes easier to work on and maintain for teams.
And as Terry Pratchett said, “It’s still magic even if you know how it’s done.”