- React Native at Airbnb
- By Gabriel Peal
- The Nuggets translation Project
- Permanent link to this article: github.com/xitu/gold-m…
- Translator: ALVINYEH
- Proofread by: ChenDongnan
React Native in Airbnb
In 2016, we made a big bet with React Native. Two years later, we are ready to share our experience and explain what we plan to do next.
Years later, we can still book a conference on Airstream
This is the first in a series of blog posts outlining our experience with React Native and what Airbnb mobile could look like.
When Airbnb launched a decade ago, smartphones were still in their infancy. Since then, smartphones have become an important tool for navigating daily life, especially now as more and more people travel the world. As a community capable of providing new forms of travel for millions of people, having a world-class app is crucial. Because mobile devices are often travelers’ primary or only form of communication while away from home.
Since 2008, when our first three guests stayed on Rausch Street, mobile bookings have increased by millions every year. Our app allows landlords to manage their listings on the fly, while also providing inspiration for travelers to discover new places and experiences with the click of a finger.
To keep up with the accelerating pace of mobile applications, we have expanded the team to more than 100 mobile engineers to enable new experiences and improve existing work.
Bet on React Native
We are constantly evaluating new technologies that enable us to improve the experience of guests and hosts when using Airbnb and to be responsive while maintaining a great developer experience. In 2016, one of those technologies was React Native. At the time, we realized how important mobile was to our business, but we didn’t have enough mobile engineers to meet our goals. So we started exploring alternatives. Our site is primarily built by React. At Airbnb, it has been a very effective and universally popular Web framework. As a result, we see React Native as an opportunity to expose more engineers to mobile development and also take advantage of its cross-platform nature to distribute code faster.
When we first decided to invest in React Native, we knew there were risks. We needed to add a new, rapidly iterating, unproven platform to the code base. The platform has the potential to fragment the code base rather than unify it. We also knew that if we were going to use React Native, we wanted to do it right. Our goals are:
- As an organization, it allows us to iterate quickly.
- Maintain original quality standards.
- Write production code once for mobile, not twice.
- Improve the developer experience.
Our experience
A great deal of effort has been put into this experiment during the past two years. We have built an incredibly powerful integration in the application, enabling complex native functions such as shared element transformations, parallax and geolocation and bridging with our existing native infrastructure such as networking, experimentation and internationalization.
We used React Native to launch a number of key products for Airbnb. React Native enables us to roll out more experiences, a brand new Airbnb business, and dozens of new features, from reviews to gift cards. These features were built at a time when we didn’t have enough engineers to accomplish our goals.
Different teams have a lot of experience with React Native. React Native has proven to be a terrific tool at times, but it can also present technical and organizational challenges at times. In this series, we detail our experience and what to do next.
In the second part, we list the effectiveness and drawbacks of React Native as a technology.
In Part 3, we list some of the organizational challenges associated with building a cross-platform mobile team.
In part 4, we focus on our position with React Native today and its future in Airbnb.
In Part 5, we’ll cover the most important things we learned from React Native and use them to make it better.
If you find any mistakes in your translation or other areas that need to be improved, you are welcome to the Nuggets Translation Program to revise and PR your translation, and you can also get the corresponding reward points. The permanent link to this article at the beginning of this article is the MarkDown link to this article on GitHub.
The Nuggets Translation Project is a community that translates quality Internet technical articles from English sharing articles on nuggets. The content covers Android, iOS, front-end, back-end, blockchain, products, design, artificial intelligence and other fields. If you want to see more high-quality translation, please continue to pay attention to the Translation plan of Digging Gold, the official Weibo, Zhihu column.