Painless React Native Setup for Mac, Windows, & Linux Part Two — Windows This is Part 2 of a three-part series covering React Native setup for Mac, Windows, & Linux. ![]() React Native Setup On WindowsThis is basically taken from a private README that I use and cleaned up for public consumption. It doesn't really have the humor that I try to bring to these things, and I tried to keep it simple for Japanese speakers that I can point here when they need help. Very quick and dirty, may clean up later. This is only for Mac. If you aren't using Mac for React Native dev - do it, it's pretty great. Setting up a react native environment Steps Software installs and file setup Install Xcode from the app store - Xcode is a program that runs iOS apps for you, and lets you start a simulator for your app so you can develop without needing a physical iPhone. Install a Java Development Kit - you need this to make Android apps in React Native Accept license agreement, Mac OS X x64 Install Android Studio (google this). This is how we will run android simulators so we don't need an Android phone open to check our work. Now, we need to set it up. Open Android Studio. Choose custom install. Check the boxes for • Android SDK • Android SDK Platform • Performance(Intel@HAXM) - this speeds up the simulator. • Android Virtual Device Begin downloads. Install Node and Node Package Manager(NPM). If you don't know what that is, literally google - install Node on MacOS. It's very painless That will take a long time, so in your terminal, enter the following (without the $ symbol). This will install watchman, a program that watches files and updates your app when they change. $brew install node watchman This will install react native so we can do cool stuff like make apps npm install -g react-native-cli Back to Xcode install the xcode command line tools. In terminal: $xcode-select --install Add the following line to your ~./bash_profile alias android-studio='open -a /Applications/Android Studio.app/' What this does (after restarting terminal) is let you open directories by typing android-studio. In that directory. Android SDK and AVD Install Open android studio once downloads finish, click on 'configure', go to SDK manager. Click 'Show package details' Enable Android 6.0 (Marshmallow), and INSIDE Marshmallow, enable • Google APIs • Android SDK platform 23 • Intel x86 Atom_64 System Image • Google APIs Intel x86 Atom_64 System Image Do the above for Android 7 and 8 as well (Not necessary, but good to have for the future) Next, on SDK tools tab, click 'Show package details', look for 'Android SDK Build-Tools', and make sure that 23.0.1 is selected click apply. Append to ~/. Minecraft camping mod download for mac. bash_profile. Export ANDROID_HOME=$HOME/Library/Android/sdk export PATH=$PATH:$ANDROID_HOME/tools export PATH=$PATH:$ANDROID_HOME/platform-tools terminal: source $HOME/.bash_profile Confirm sdk location with echo $PATH We just did all that because really we have no choice. That's the work necessary to make Android apps. Painless React Native Setup For MacNew project Setup a project really quick to configure the emulators. In terminal, start a new project with $react-native init $cd $npm install Note, you can use Yarn as well (google install Yarn) Running on iOS In a terminal, type $react-native run-ios from your react native project folder Confirm that app runs.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |