Install expo :
npm install --global expo-cli
Initial a new React-native project with expo :
expo init my-app
Start developement server :
expo start
expo build:android -t apk
First time: install eas-cli using
npm install -g eas-cli
Then, every time we need build, we can use:
eas build -p android
04- Building APKs for Android emulators and devices : Link
first, change eas.json
file like this:
{
"build": {
"preview": {
"android": {
"buildType": "apk"
}
},
"preview2": {
"android": {
"gradleCommand": ":app:assembleRelease"
}
},
"preview3": {
"developmentClient": true
},
"production": {}
}
}
then, use this command:
eas build -p android --profile preview
05- Clearing bundler caches on Windows based on expo website
del node_modules
npm cache clean --force
npm install
watchman watch-del-all
del %appdata%\Temp\haste-map-* // File
del %appdata%\Temp\metro-cache //Folder
expo start --clear