Node.js
Android
JDK (Java SE Development Kit)
Android Studio
IOS
Xcode
CocoaPods
Watchman
IOS
Brew
To install the dependencies, we will use Brew which is a dependency manager for Mac.
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
Node, Watchman
Once Brew is installed, proceed to install Node and Watchman with the following commands:
brew install node
brew install watchman
Xcode
To install Xcode we must open
App Store and in the search engine type Xcode and in the results you will see Xcode and we will click on install.
Once installed, go to the menu File → Preferences → Locations
and in the
Command Line Tools section select the latest version of Xcode this will install Command Line Tools.
Cocoapods
Now install Cocoapods by simply running the following command for this:
sudo gem install cocoapods
PS: With this requirements, now you are already have what we need to run our application on iOS.
Android
JDK
Now we will install Java Development Kit via brew or you can download it here: https://www.oracle.com/java/technologies/javase/javase-jdk8-downloads.html
brew cask install adoptopenjdk/openjdk/adoptopenjdk8
Android Studio
Go to this link: https://developer.android.com/studio/index.html
Run the installer and make sure to select the following options
Android SDK
Android SDK Platform
Android Virtual Device
Make sure that, you also have the Android 10 SDK installed.
Check this in Preferences → Appearance and Behavior → System Settings → Android SDK
and in the SDK Platforms tab:
Inside the Android SDK go to the SDK Tools tab and make sure that
Android SDK Build-Tools is selected.
Finally, once everything is selected, click on the Apply button and if anything is missing, it will be installed.
We must configure the environment variables
export ANDROID_HOME=$HOME/Library/Android/sdk
export PATH=$PATH:$ANDROID_HOME/emulator
export PATH=$PATH:$ANDROID_HOME/tools
export PATH=$PATH:$ANDROID_HOME/tools/bin
export PATH=$PATH:$ANDROID_HOME/platform-tools
If you have some problems you can follow this guide in the section "React Native CLI Quickstart".
https://reactnative.dev/docs/environment-setup
Now you must open the attached repository and perform the following steps from the terminal:
yarn install
yarn install -D react native
cd example
yarn install
IOS
cd ios
delete Pods folder
run pod install
cd ..
npx react-native run-ios
Android
npx react-native run-android
If you need anything else from your Ordering Team, let us know.
As Always, Happy Ordering.