- Once you learn to use React with Rails, you can also use React Native to build mobile apps for the same API.
- Rails developers should learn React because there’s growing market demand for developers who know both.
- There are also other ways to use React with Rails.
- As the tooling around React improves (see Create React App ), the initial hurdles to getting productive with React will also disappear (as they did with Rails).
- The way, your investment in learning React gives you the chance to easily build cross-platform apps.
Learnetto: Online courses for learning to make web and mobile apps
@lrntto: Why Rails developers should learn React – by @hrishio #rubyonrails #reactjs
Rails developers should learn React because there’s growing market demand for developers who know both. Learning to use React will make you more money and a better developer.
In many ways, React is to the modern frontend, what Rails is to the backend – there are many alternatives, but React has the best combination of simplicity, power and community momentum to make it a great choice.
Web UIs have matured a lot over the last decade. We’re doing more complex things to build better user experiences on the web. jQuery has served well but even a medium-sized project can now quickly turn into the Flying Spaghetti Monster. React offers a simple yet powerful alternative to spaghetti code.
The truth is that React has been out for more than 3 years now and it looks like it’s here to stay. It may be tempting to just stick to jQuery and ignore React because it looks alien and intimidating (Babel, Webpack, ES6, Redux, Flux, MobX, transpiler, transmogrifier…why do I need all this??).
But you’ll do well to pay attention to the changing market and make sure your skills match what employers and clients are looking for in 2017.
There’s a huge and growing market demand for React developers. Many companies are moving their frontend away from plain Rails templates and jQuery over to React, so learning React would give you a unique advantage over others vying for the same jobs.
Even if React itself is replaced by something else, the concept of reactive UI – UI as functional components is here to stay. So it’ll help you a great deal to learn to use it.
Coming from an imperative background, React’s declarative approach will make you see software in a different light and make you a better developer.
It’s your chance to get into mobile development
Once you learn to use React with Rails, you can also use React Native to build mobile apps for the same API. This way, your investment in learning React gives you the chance to easily build cross-platform apps.
It’s early days yet, but React Native looks very promising in terms of code re-use and performance. For example, Facebook Ads Manager shares 85-90% of code between its iOS and Android apps and were built by a single team.
If you have been meaning to try your hand at making an iOS or Android app, but just haven’t got around to it, React could be your gateway drug to building mobile apps.
This is yet another way to increase your market value.
But isn’t it overkill?
You’re probably wondering… isn’t React overkill for small projects? It probably is – I am not convinced one way or the other, yet.
The problem is when you’re working in a team you don’t often have the luxury of rewriting the whole app. You’re often stuck with your initial choice. Since many people are finding React superior at least for medium to large projects, you might want to consider using it right from the start of a project if you expect it to grow into more than a small side project.
As the tooling around React improves (see Create React App), the initial hurdles to getting productive with React will also disappear (as they did with Rails).
Ok, so you’re convinced you should learn React, but where to start?
First, check out the official React tutorial. You can familiarise yourself with the basics quite quickly. Once you’ve done that you can start looking into how to integrate React with Rails. There are two popular gems – react-rails and react_on_rails.
There are many pros and cons and different configurations for using these gems. There are also other ways to use React with Rails.
I’m working on a comprehensive course on using React with Rails. It’ll answer the most common and important scenarios with hands-on video and text lessons. You can check out more details of the course here and sign up to get notified when it launches.