yarn
- Copy the .env file
cp .env.sample .env
and modify it
- Run dev server:
yarn start
- Select what you want to run:
- App
- Android
- Logs:
yarn log:android
- Build app:
yarn run:android
- Logs:
- iOS
- Logs:
yarn log:ios
- Build app:
yarn run:ios
- Logs:
- Android
- Storybook
- Run storybook server:
yarn storybook
- Android
- Build Storybook app:
yarn run:android-storybook
- Web UI: http://localhost:7007/
- Build Storybook app:
- Android
- Run storybook server:
- React Developer Tools
- install:
npm install -g react-devtools
- run:
react-devtools
- install:
yarn postinstall
// TODO: remove when Apollo fix this: apollographql/apollo-client#3236
Investigate this: https://reactnativetesting.io/ TODO: Fill this section
- How to debug the subscriptions:
- Start the subscription in the app
- Run in the Postman (via GET):
*DEV_PLATFORM_URL*/*INTEGRATION_PATH*/subscriptions/*streamId value from the subscriptions table (ow_esapi_subscription)*
(for example: http://192.168.0.100/oxwall/iola/api/subscriptions/5f1e34db2cf318ae) - Run mutation that triggers the subscription (for example from GraphiQL interface)
- How to debug Java errors:
adb logcat *:E
- "Metro Bundler can't listen on port 8081" error (or "Error: listen EADDRINUSE :::7007")
sudo lsof -i :8081
kill -9 *PID from the previous command results*
- Airbnb Code Style
- Destructuring: in one line if length < 100 but in multiple lines if has default values
- Setup the environment:
- Common:
- nvm with Node.js v10.15.3:
nvm install 10.15.3
(used in prod build:/usr/local/opt/nvm/versions/node/v10.15.3/bin/node
) // @DEPRECATED - Install Fastlane
bundle install
- Fill the
FASTLANE_APPLE_APPLICATION_SPECIFIC_PASSWORD
in the .env file:- Go to https://appleid.apple.com/account/manage
- Click "Generate Password…" link under the "APP-SPECIFIC PASSWORDS" section
- nvm with Node.js v10.15.3:
- Android:
- passwords.properties:
cp android/passwords.properties.sample android/passwords.properties
and fill it - debug.keystore:
cd android/app; keytool -genkey -v -keystore debug.keystore -storepass android -alias androiddebugkey -keypass android -keyalg RSA -keysize 2048 -validity 10000
- passwords.properties:
- iOS:
- Install CocoaPods
pod install
- Test the release app version:
- Android
- Uninstall the previous version of the app you already have installed
- Build the .apk file + install it on emulator/device:
yarn release:test:android
- iOS:
yarn fastlane:ios:beta
- Build the release app version (build the apk file):
- Sometimes you'll need to
cd android && ./gradlew clean
before release - Android:
yarn release:build:android
- See:
https://github.com/react-native-community/react-native-blur/issues/310#issuecomment-503816482
- See:
- Get the new .aab (Android App Bundle) file here:
./android/app/build/outputs/bundle/applicationRelease
- iOS: TODO
- Change the app icon:
- Online Android Asset Studio
- After going live add the
lint:fix
action to pre-commit hook (via Husky)