The very first step to start development in React-Native is to install the right tools to setup the environment correctly. I’m working on MacOS Catalina and I already have Xcode 11 installed on my machine which is one of the pre-requisites to run the iOS App.
Install React Native Tools Extension (provided by Microsoft) to VS Code. This is a nice add on to VS Code's capabilities for React Native. Then go to Debug option from left menu and click on Add Configuration. If it initially says No Configuration then you can click on Add Configuration and then choose React Native option. Configure Visual Studio Code for React Native Development. Your editor is your extension into the world of code. I use Visual Studio Code as my editor and have made a number of configuration changes and installations to turbocharge my React Native workflow. Link donate:: Page: https://www.facebook.com/Lirs-Tech-Tips-111449010.
Install the following dependencies for React-Native:
Android studio 2.2 download for mac. NodeJS: https://nodejs.org/en/download/
The recommended way to install Node is using Homebrew from your Terminal:
Watchman: In react-native, Watchman watches the source code for any changes and rebuilds them.
Install XCode from App Store.
Cocoapods: This is the Dependency Manager for iOS & Mac projects.
This requires you to enter system password.
Install Visual Studio Code for Mac from here. You might face issues on Mac OS Catalina to run VS Code due to Notarization requirements. You can check out this post for more details.
Create the folder inside say your Documents folder on your Mac as below:
Open VS Code and open New Terminal and type the following command to create a new React-Native App:
Come back to the MyApp folder and run the below command to run your App in the iOS simulator:
This will install and launch the App in your iOS simulator. The first time might be very slow. It might be helpful to launch your simulator beforehand.
Running on Android:
Install the Android Studio from here, which will install the Android SDK and the required emulator. I’m using the Android 10 emulator for Pixel XL.
Download 13,301 paint brush free vectors. Choose from over a million free vectors, clipart graphics, vector art images, design templates, and illustrations created by artists worldwide! Illustrator Brushes Vectors. Collection multicolor heart, cake and other elements illustration. Set of brush strokes. Grunge design elements. Golden paint, ink, brushes, lines, grungy. Dirty artistic boxes, frames. Gold lines isolated. Abstract gold glittering textured art illustration. Paint brush vector illustrator. The Paintbrush Tool in Illustrator. Basically, the paint brush in Illustrator functions like the Pencil Tool, allowing you to click and drag to create a path. The difference is that Illustrator's Paintbrush Tool (B) applies predefined vector art to the paths you create. This might seem like a simple distinction, but using brushes will greatly improve your Illustrator.
Open the MyApp folder in VS Code to make further changes.
Issues
Visual Studio Code React Native Debug
Running the Android App causes issues while launching the Emulator. The error message is: React Native adb reverse ENOENT
Starting with macOS Catalina, your Mac uses zsh as the default login shell and interactive shell. You can make zsh the default in earlier versions of macOS as well.
Visual Studio Code React Native
So on your Mac:
1 – Open your .zshrc file:
2 – if .zshrc file doesn’t exist, you need to create one & open again(Step 1)
Visual Studio Code React Native
3 – Add this to your .zshrc file
4 – Save and close
5 – Compile your changes
& make sure to restart your terminal.
Run the command in the Terminal and you’ll see something like below if everything is fine:
Android Debug Bridge version 1.0.41
Version 30.0.0-6374843
Visual Studio Code React Native Debugger
Installed as /Users/<username>/Library/Android/sdk/platform-tools/adb
Visual Studio Code React Native Tools
You can also run the code in your VS Code Terminal and see the same output.
Visual Studio Code React Native Tutorial
The path to Android SDK is available in the Configure button -> SDK Manager (at the bottom right) when you launch Android Studio.