Lesson 1: React native Environment: Set up - udaisshekhawat/ReactNativeTutorial GitHub Wiki

Two ways to set up React native development environment:

  1. expo-cli (create-react-native-app)

  2. react-native-cli

  3. expo-cli (create-react-native-app) A command line utility for configuring React native projects. This tool generates a QR code. Scan this QR code to launch the App within your device. The changes are reflected when you save your code changes. Uses default export of App.js as your App root component.

Drawback: Does not allow usage of custom native modules like Java, Kotlin, Objective C, Swift.

  1. react-native-cli Best to use to create your app when you know that you will be using custom native module. The registering of the root component is required when you use react-native-cli. This can be done using AppRegistry.registerComponent

import { AppRegistry } from 'react-native';

import App from './App';

import { appName } from './app.json';

AppRegistry.registerComponent(appName, () => App);


Instructions to set up: https://facebook.github.io/react-native/docs/getting-started.html