How React Native Is The Answer To The Cross Platform Woes

Since Facebook announced React in 2013, it’s been receiving widespread attention. But like any new framework, it would need to grow and mature before it was a viable option for production code. The moment we knew it had come into its own happened at Codemash in Sandusky, Ohio this past January. We’d attended a session entitled Why I Left Angular and Knockout for React presented by Corey House. Honestly, I was so intrigued, I skipped the next session to learn the framework and ended up spending that afternoon building an app. But let’s back up. It was more than a single event that lead to the eventual testing, and subsequent adoption, of the framework. Really, it was a perfect storm of demands and inadequate solutions.

The Problem That Needed Solving

We needed a cross-platform solution for mobile and we had yet to find a solution that catered equally to the triangle of concerns encountered when developing a product: business, design, and engineering. There were several options that solved one or two of these needs, but we were still left with compromise and work-arounds to finish the work.

With the introduction of React Native, we found a tool that enabled all three sides of the triangle to be in balance. We were able to address business concerns like cost and time-to-market, the quality of design and user interaction no longer needed to be compromised, and developers were empowered to quickly craft elegant code. Even more important than any individual component, the balance meant our team was freed to collaborate, yielding a stronger product and company.

Why We Chose To Investigate

They had us at native. For a couple of years, the tools that underpinned our web projects enabled increasingly quicker cycles of development; yet mobile tooling lagged behind. Once we saw that React Native enabled the same speed in workflow through HMR, Hot Module Replacement, we knew we’d seen the future of mobile.

Although somewhat subtle, the power of HMR is in shaving seconds off each of the hundreds of development cycles that go into developing a product feature. Put simply, HMR allows code to be updated in place in a running app. This means we can change the logic and style of an app without restarting it – eliminating repetitive tasks and context switching.

Another factor worth investigating is React’s emphasis on creating small building blocks called ‘components’. These allow the code to be broken into simple, reusable pieces. When combined with React’s immutable, unidirectional data-flow (implemented through Redux), the code becomes more readable, easier to maintain, and better for testing – basically more solid.

The Impacts Its Had

React is having a significant disruptive impact on the industry. It is removing barriers to creating software allowing us to better serve our clients. We’re seeing a faster turn around from the inception of an idea to execution – it makes the process faster and more collaborative.

Intrigued? Join the nearly 600 members of the ReactPgh group on Meetup, started by a few Truefit team members. They meet monthly in our new offices for snack-fueled discovery.