You will need Node, the React Native command line interface, Python2, a JDK, and Android Studio. While you can use any editor of your choice to develop your app, you will need to install Android Studio in order to set up the necessary tooling to build your React Native app for Android.
Setting up for Linux
Dependencies (Install instructions below)
sudo apt-get install -y nodejs
ii. React Native CLI
npm i -g react-native-cli
iii. Java Developer Kit
1. You will need your Linux version: Get it by typing hostnamectl in your terminal
2. Download the correct JDK file from here
3. Extract the JDK package and you are good to go. (Usually just double click on the downloaded file and the files should be extracted to root for you).
iv. Android Studio
1. Download Android Studio here
2. Extract the download to a folder of your choice (or just root directory).
5. Check "Do not import settings" when prompted. (Unless you have a previous version of Android Studio and you'd like to import its configs).
6. Follow the Wizard
7. Check all boxes for:
Android SDK, Intel x86 Atom_64 System Image or Google APIs Intel x86 Atom System Image, Android SDK Platform API 28 or greater , Android Virtual Device
8. Finish and download!
9. When it's finished downloading, you can close Android Studio
Configure JAVA_HOME & ANDROID_HOME environment variables
Check if you have a
.bash_profile file in your root directory with command
ls -a in your terminal and check for the
If you don't have a .bash_profile in your root directory create it with command
Open your bash profile by command
nano .bash_profile and add:
export JAVA_HOME="$HOME/jdk1.8.0_181" // Or your version of the jdk export PATH=$PATH: "$JAVA_HOME/bin" export ANDROID_HOME=$HOME/Android/Sdk export PATH=$PATH:$ANDROID_HOME/tools export PATH=$PATH:$ANDROID_HOME/tools/bin export PATH=$PATH:$ANDROID_HOME/platform-tools export PATH=$PATH:$ANDROID_HOME/emulator
Then ctrl + o to write out, hit Enter and then ctrl + x to close the editor
First install Linuxbrew:
sudo apt install linuxbrew-wrapper
brew update && brew install watchman (might get a warning, just hit Enter)
.bashrc for correct path to
npm list -g | head -n 1 will give you the path to
Now let's add the path to npm into the
Now you're ready to create your first React Native App!
You may folow this article to create your first react native app.
Search for posts
04 Jan, 2018
01 Jan, 2018
06 Jan, 2018
03 Jan, 2018
13 Oct, 2020
12 Oct, 2020
10 Oct, 2020