Install React Native Cli
Setup environment in React Native
Install package
# Install npm packages
npm install
# Install pod
cd ios
pod install
Build Android
# default debug
npm run android
Build iOS
# default debug
npm run ios
For more environments build, please refer script in package.json
-
In root project generate
index.android.bundle
# For debug build npx react-native bundle --platform android --dev false --entry-file index.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res
-
Go to android folder
cd android # Debug # Generate the .AAB file: ./gradlew bundleDevelopmentDebug # or Generate the .APK file: ./gradlew assembleDevelopmentDebug # Release # Generate the .AAB file: ./gradlew bundleDevelopmentRelease # or Generate the .APK file: ./gradlew assembleDevelopmentRelease
Output apk, aab files in path:
/android/app/build/outputs
-
Reference
-
In root project generate
main.jsbundle
npx react-native bundle --entry-file index.js --platform ios --dev false --bundle-output ios/main.jsbundle --assets-dest ios
-
Publish .iap file publishing
- TypeScript
- React Navigation
- GraphQL (Apollo Client, Hasura)
- Redux
- React Hook