How to Setup your First app with React Native and Expo in Linux & Windows
In this article,we will see how to install react native with expo.
For Linux:
1. Verify the installation of npm and node.
2 3 |
$ npm -v $ node -v |
if nodejs is not installed:
2 3 |
$ sudo apt-get update $ sudo apt-get install nodejs |
If the package in the repositories suits your needs, this is all you need to do to get set up with Node.js. In most cases, you’ll also want to also install npm
, which is the Node.js package manager. You can do this by typing:
2 |
$ sudo apt-get install npm |
Have a look at the related article if you like
2. Install the React Native CLI.
You may install this using the following command :
2 |
$ npm install -g react-native-cli |
3. Install the Expo
2 |
$ npm install expo-cli --global |
Create your first project
You will be asked to create an Expo account before proceeding.
2 3 4 |
$ expo init my-first-app $ cd my-first-app $ expo start |
For Windows:
1. Firstly,setup the NodeJS
2. Install the React Native CLI.
2 |
npm install -g react-native-cli |
3. Install the Expo
You may install this using the following command :
2 |
npm install -g expo-cli |
Demo
You can read the barcode by selecting the tunnel option from the tab below.
If you do not have an expo application for android and ios, you can download the application from the market as an expo.
If you have an expo account, an option like on the screen will appear.
Scan QR Code:
if you have question do not forget to write from the chat button next to it or from the comment
Recent Comments