Installing dependencies for React Native

Here we will use the Expo CLI version which makes it much smoother to run your React Native applications. Follow the below steps one by one to set up your React native environment.

Expo: It is a framework and a platform for universal React applications. It is a set of tools and services built around React Native and native platforms that help you develop, build, deploy, and quickly iterate on iOS, Android, and web apps from the same JavaScript/TypeScript codebase.

Step 1: Open your terminal and run the below command.

npm install -g expo-cli

Step 2: Now expo-cli is globally installed so you can create the project folder by running the below command.

expo init "projectName"

Step 3: Now go into the created folder and start the server by using the following command.

cd "projectName"
npm start web

Or to run it on simulator use the following command.

npx expo start

Then press ā€˜aā€™ or ā€˜iā€™ to open it in your android or ios emulator respectively.

Getting started with React Native

React Native, also known as RN, is a widely used mobile app framework that relies on JavaScript and It enables developers to build natively-rendered apps for both iOS and Android platforms using the same codebase was introduced by Facebook as an open-source project in 2015 and quickly became one of the leading solutions for mobile app development. Major mobile apps such as Instagram, Facebook, and Skype are powered by React Native.

Table of Content

  • What is React Native ?
  • Getting Started with React Native
  • Installing dependencies for React Native
  • First React Native App Example:
  • Things to remember while starting React Native

React Nativeā€™s success can be attributed to several reasons. Firstly, React Native allows companies to write code once and use it for both their iOS and Android apps, saving significant time and resources, Secondly, React Native was built using React, a popular JavaScript library that was already well-established when the mobile framework was released and Thirdly, the framework empowered front-end developers, who previously could only work with web-based technologies, to create robust, production-ready apps for mobile platforms.

Similar Reads

What is React Native?

React Native is a framework developed by Facebook for creating native-style apps for iOS & Android under one common language, JavaScript.Ā Initially, Facebook only developed React Native to support iOS. However, with its recent support of the Android operating system, the library can now render mobile UIs for both platforms....

Getting Started with React Native

Building with React Native is extremely efficient and highly addictive but getting started can be a little tricky. React Native uses Node.js, a JavaScript runtime, to build your JavaScript code. If you donā€™t already have Node.js installed, itā€™s time to get it!...

Installing dependencies for React Native

Here we will use the Expo CLI version which makes it much smoother to run your React Native applications. Follow the below steps one by one to set up your React native environment....

First React Native App Example

This example demonstrates a simple react-native app....

Things to remember while starting React Native

...

Contact Us