React Native Interview Questions
React Native

React Native Interview Questions

Over the years, we’ve evaluated thousands of React Native developers, carefully honing our interview skills and constantly improving our vetting process by asking the right questions.

React Native Interview Questions

Simply put—developers are makers. They build apps, services, and interfaces into existence. But, no two developers are exactly alike. They might have different skill sets. They might be specialists in different programming languages. Or, they might be experts in building one particular type of app. This principle applies to React Native developers as well. So, let’s dive into what makes a good React Native developer, the tools they use to get their work done, and most importantly, which questions you can ask a React Native Developer during a technical interview to get a sense of their skillset.

What is React Native?

React Native developers typically build native apps on the two dominant mobile platforms—iOS and Android. But, that universe is rapidly expanding. Now, React Native developers might build an app for Windows or Mac OSX, or construct an app that can run on a TV. The primary focus of a React Native developer is building those apps across platforms, and across industries. React Native developers use flexible tools like JavaScript that make their work both accessible and valuable across various industries and at leading companies like Microsoft, Facebook, Twitter, Discord, Teslas, Bloomberg, Wix, Artsy, and others.

This should come as no surprise, but a large part of a developer’s day is writing code that will eventually grow to define and shape a user’s interface. You may have guessed, but I’m a React Native developer myself. When I’m working on a new application, two critical parts of my journey are writing UI code and mapping data that’s ferried into and out from the application itself. Although, there’s always more work to be done.

Some roles require the React Native developer to build, test, and release the app. This means developers should have a good understanding of building workflows, continuous integration, and testing tools. We’ve covered a few tasks developers accomplish when building apps. Now, let’s unpack the various tools and frameworks they use to power those apps. 

React Native Developer Tools & Frameworks

The React Native Framework consists of JavaScript code that is embedded inside a Native app and interpreted using a JavaScript engine. Depending on the platform, the framework logic is written either in C++ or with the platform's default language. This fact makes the React Native developers' job a bit harder since they are writing JavaScript code inside a Native App. This dynamic results in more exposure to the native software development environments.

React Native developers have a high-level view and deep understanding of how and when to call the native layers to leverage features that might be unavailable within the confines of the React Native framework. To do this, developers leverage tools like Xcode and Android Studio while dealing with third-party native dependencies.

It is not uncommon for React Native job listings to request developers to have extensive experience with native development. Some teams might even actually prefer developers with a native development background, rather than a web-based background.

That preference might be a little misguided given that a React Native is more exposed in the JavaScript layer.

Let’s breakdown a React Native developer's role so we can see its component parts and understand what defines a developer’s day-to-day work:

  • Writing JavaScript
  • Handling network data and local state in JavaScript
  • Writing React components
  • Writing React Native layouts Integrating native modules Building and releasing apps

A developer's first goal should be to support the full lifecycle of the product, taking what they’ve built, getting it through testing, and to the end-users. 

While some teams can establish a certain paradigm to follow, like a functional paradigm, codebases written with JavaScript are always flexible, willing to mold to whatever that specific company or set of developers consider the best of all the worlds. This is why it’s so important for React Native developers to have a strong foundation in JavaScript.

React Native app development is composed of knowledge bubbles. A React Native developer is first a software developer before anything else. Not every developer will go deep into the platform-specific bubbles, and a shallow understanding of some of these bubbles is often enough to be productive.

React Native App Development Skills

When someone is writing a React Native app they will use JavaScript and React to create components. While two ingredients might seem easy to manage, there are so many variables that a developer needs to wrangle to produce a functional application. Let’s take one example — deciding between component types.

Before React 16.8 came out, a developer would either use a Class component or a functional component when writing a new component. The decision to go with a Class Component normally meant that the developer needed to use the lifecycle methods and or local state.

In order to use a Class component, the developer had to know how to instantiate an ES6 JavaScript class. They also had to have an understanding of the pitfalls of using this keyword within a method of the class and how class fields and arrow functions could fix this keyword problem, which React lifecycle methods were adequate for them to use, the impact of inlined values, how to use the local state API avoiding mutation and a whole lot more. This is not at all an exhaustive list, but it illustrates the depth of granular knowledge a React Native developer has to have when writing a new application.

While anyone can write React components and React Native apps. It takes someone with a certain level of fluency to excel at React Native development. Some companies don’t have the luxury of waiting for a developer to ramp up on React Native after they’re hired.

They might require someone to be productive from day one. And in these cases, coming in with a deep knowledge of React and React Native is a must.

Thus, a React Native developer is someone who is very confident with JavaScript, has a strong understanding of React's model, knows React Native's layout components, and might have either a shallow or deep understanding of the platform-specific development tools. As we progress into the higher-level roles, developer knowledge expands into new areas:

  • Fluency in modern JavaScript (ES6+). You can make decisions on the best approach to solving problems with JavaScript.
  • Fluency with React.
  • Knowledge of how to write UI layouts with React Native components.
  • Understands version control and git.
  • Experience with the Android and iOS development environment.
  • Ability to estimate how long a task will take.
  • Understanding of a Native Module and how it can be integrated with each native platform.
  • Experience and understanding of codebases that leverage X state management solution.
  • Ownership of the product you are developing and you are interested in the intricacies of the product you are developing.

No two teams are alike. You might lack some specific platform expertise like iOS and Android. You may need a high-level strategist like a senior developer. Your main job is to identify your deficiencies, and once you have asserted the basic requirements for a React Native developer you can then focus on vetting for what you specifically need.

We have had interesting experiences with finding out about specific traits of a developer that were not explicitly mentioned in their curriculum or LinkedIn profile. For example, one developer we interviewed for a React Native role, despite not sharing this on his resume, had extensive experience with writing Android apps with Java. In another case, we found out someone was a natural leader, and given his amazing communication skills and natural instincts, we thought he could be a technical leader.

What kind of role will the newly hired individual play inside your company? What is your company’s atmosphere like? Who will this developer work with? These questions are incredibly important.

We often see an excessive delegation of responsibilities where a React Native developer is doing the job of a Scrum Master and team lead due to the lack of engineering leads in the company. There is nothing wrong with this. But, it’s best to signal these roles in the interview, rather than the onboarding.

The company hiring needs a clear vision of what they are hiring for and why before they send a contract to a developer. Some companies like to look for experience in their industry. While this can certainly be a bonus, it shouldn’t be a deal-breaker. Someone with experience in the finance field will be oriented to different details than someone with media application experience, but they’re both adept developers. Developers with experience in other fields can learn your business fundamentals and also bring more to the table.

Try to identify the kind of team you have inside your company and what kind of developer you need to hire. Here are a few examples of typical team dynamics and traits:

  1. Structured Team Dynamics

This type of team is usually composed of teams with clear leads, project managers, scrum master, and design team. The developer often ends up having a more constrained role such as finishing tasks to achieve the sprint goals.

  1. Unstructured Team Dynamics

This type of team features more generalists. They often have closer relationships to one another’s work and more inter-dependency amongst their tasks. The developer has a high impact on the outcomes but also is way more involved in planning, deciding UI, and architecture.

React Native Interview Questions

What should a React Native developer know? What can I expect them to say when prompted with these questions?

We won’t attempt to gloss over complex answers with simple points. The truth is more than one possible answer is correct and the goal of this exercise is to use a somewhat Socratic method so you can ask the right questions and find the right candidate for the job.

In order to go over the fundamentals of React Native, let’s imagine what the start, middle, and end of a React Native project would look like. This way, we can rehearse what kind of challenges a React Native developer would encounter throughout the lifetime of a project, and focus on validating the knowledge of the elements that compose these phases.

Ask basic questions. Don’t take any information for granted or prime the candidate with any previous knowledge. Developers with experience will shine when you ask them open-ended questions without much windup.

Questions About How to Get Started Building A React Native App

A project starts with an initial template. So, you might consider asking the following types of questions.

How can I start a React Native Project?

What kind of insights can we derive from this question?

The first answer might be using the React Native Command Line Tool. They can mention how you can start a clean project by typing react-native init my_project or with npx react-native init my_project. They can raise the point of how the React Native CLI's init command outputs an app without any features and native modules, and thus will require more manual work to set up a launch screen, icons, and possibly any other native specific features your app requires.

Always remember that when you’re asking these questions, you’re trying to assess the developer’s knowledge base, not coach them on the proper response.

Another possible answer is using Expo CLI. Expo provides you with an SDK for React Native which includes native modules, multiple project templates, plus extra configurations to get started fast with your project. He might mention how expo has an app for easy beta testing, plus how it supports Web by default.

Often, developers with more experience will also make points on the flaws of each option. If they don't, you can also ask.

What are the drawbacks of using Expo and the React Native CLI?

No technology is perfect. The React Native CLI does not come with all the required features. You are unlikely to finish your app with only what the React Native CLI outputted, thus it might require more manual work and integration with the native counterparts. On the other hand, while Expo tries its best to be a complete SDK, some teams might complain it is too bloated with features they don't use, and thus results in a large APK or IPA file.

Let’s dig a little deeper into this situation. For instance, Expo has changed its strategy in recent years to actually include two different workflows: bare and managed. Expo's main goal with this change was to allow teams to take advantage of Expo's APIs without all of the bloat, and this can be achieved via the bare workflow.

You don't always start a new project very frequently. However, the understanding of how this process happens can point out to you just about how much practice someone has had with React Native. Initializing new projects is the first thing someone does when playing with React Native to prove out some idea.

Questions on How to Manage the Layout of a React Native App

What do you think is the right way to write and compose your React Native components?

Once your project is initialized, the next obvious task is to start writing the app. There’s no one perfect way to write React Native Apps. Different teams have different strategies. But, we have noticed two common approaches we prefer that we’ll call the bottom-up and the top-down approaches to writing React Native apps.

In the bottom-up approach, the team breaks down the screens as reusable components. Then, they write tasks to create these reusable components and divide these tasks between the team. The main goal is to have a component library that will be used to compose the main pages of your app. These components must be self-contained, and once done, the developer can proceed to build the pages with these reusable pieces, adding the data integration requirements last.

The top-down approach does not start with the components that compose the screen. It instead starts off with the screens. Each developer gets assigned to an entire page, and they work from the data integration requirements, down to the page components, writing lastly the pieces of components their page requires. They might or not be aware of the reusable components.

Whichever approach your team takes, there are clearly two distinctive parts to writing the app. The layout and data integration. The latter is mostly indifferent to React Native, and more connected to state and networking logic, which are ubiquitous in every JavaScript and React app. The former is a base of React Native apps, which we recommend you validate your developer feels comfortable with.

How is layout managed in React Native?

The keyword you should hear after asking this question is Flexbox. Under the hood, React Native uses a library named Yoga, which offers a simple and intuitive layout API for multiple platforms. Flexbot’s naming convention and ideas are clearly connected to React Native. And on React Native's documentation, it says the layout is traditionally done using Flexbox.

Another main difference developers who have worked with the Web will often mention is the difference between React Native's Flexbox and the Web's. The default flex-direction is different. The default main-axis on the web is "row", while on React Native it is "column". This is a common source of confusion Web developers have when starting out with React Native.

You can ask about styling. React Native allows you to style its components using the style prop. The StyleSheet is an API provided by React Native for you to construct the style objects. It provides multiple methods and properties for you to use like create, flatten, and absoluteFillObject.

From our experience at G2i, we have noticed most developers who are fluent in React Native won't require any counter proof questions to their overall understanding. However, there are moments where you might just need to rule out that someone is not an imposter. An easy way to do so is by asking a very simple question which anyone who has written React Native UI for more than a month might know from the top of their head.

How do you center a View component on the screen?

There is more than one possible answer to this, unfortunately. But, the most common answer will be using the Flexbox system in your favor. By setting the justify-content and align-items to center should be enough for this question. Plus points can be given for those who can remember that you might need to double-check if the container of the View component is taking the complete space of the screen by setting flex: 1.

How can I handle the layout for different screen sizes?

One of the challenges your app will face for being cross-platform is the different screen sizes. Your UI layouts are required to take this into consideration. The main mistake made when writing layouts withReact Native is using fixed values for size and positioning. Thus, a React Native developer who has experienced seeing his app render on an iPhone 11 and on an Android Nexus will know he must use Flexbox with a combination of checks for screen widths and heights using the Dimension API. And again, there isn't a single solution to the problem. But, what we want to hear from the developer is awareness, and what he thinks of the problem. Completely unawareness of this problem can indicate inexperience.

There can be more about layouts. Ideally, your React Native technical interview should be heavily shaped by what the developer can expect to build on your project. For instance, if your company is building TV apps, you should raise questions on how focus can be handled on TV apps.

Once we have initialized the App, done the basic layout, the next challenge the developer will encounter is responding to user events.

Questions on How to Manage UX in React Native

While you shouldn’t focus on keywords, or buzz terms, I find it hard for someone to explain how we respond to user events in React Native without mentioning onPress, GestureHandler, PanResponder, andReact Native's touchable components. At least one of these words should be brought up. The focus here is not to ask: Do you know what the GestureHandler is? But rather, to try to derive from a normal conversation how the developer would achieve something and see if any mentions to these are made.

How do you respond to a user press in a React Native Component?

Despite the different possibilities on how to achieve this, the main one is attaching a callback to the on Pressprop of the given component. They could deliberately discourse into all of the press callbacks like on PressIn, onLongPress and etc. But at this point, you can feel confident with their answer.

React Native provides us with multiple components to handle touches, plus a gesture responding system for more complex use cases. The GestureHandler system is something that most are aware of, but very few have actually used it directly since it is a very low-level API. The previous idea comes to show the thin line of vetting someone for real requirements versus specific expertise on things 99% of apps don't require their developers to use.

G2i pairs incredible companies with incredibly talented developers

G2i is the only marketplace for specialized developers. We focus on finding and vetting JavaScript developers that have deep domain knowledge in one or two areas. When you hire a React Native developer on the G2i platform, they will have passed a test specifically designed to vet their intricate knowledge of the ins and outs of React Native.

This blog post is a snippet from our latest eBook. Looking for even more React Native developer interview questions? Download the entire eBook to see the full list of questions.


Looking for the best pre-vetted developers?

We have React, React Native, and Node.js developers available on a contract or full-time basis.


Related Articles