Forked from dmandrade/gist:e76a2da8da8a325f3ab9e275da15d5d9
Created
February 9, 2024 11:40
-
-
Save yagizhanNY/c6a6d8846facf51247f57341e4648d02 to your computer and use it in GitHub Desktop.
React Native build unsigned apk without development server
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# create assets folder in the current project | |
$ mkdir android/app/src/main/assets | |
# create bundle script | |
$ 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/ | |
# execute command to run android to create debug apk | |
$ react-native run-android | |
# change to android folder | |
$ cd android | |
# build debug apk | |
$ ./gradlew assembleDebug | |
# install app | |
$ ./gradlew :app:installDebug |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment