ReactNative application for Explorer
These pre-requisites only need to be performed once. Just skip any that you have already completed.
- Install NodeJS (version >= 8.x.x required).
- Install XCode (OS X required)
- Install Android Studio
- Install the
Expo
app on your mobile device (from AppStore or PlayStore). - Open the
Expo
app, and either sign-up or sign-in. - Install react-native-cli for help with logging
cd explorer-app
npm install
Launching in simulator:
- iOS:
npm run ios
- Android:
npm run android
Launching on mobile device:
- Start dev server:
npm start
- Launch the app:
- iOS: press
s
, and follow the prompts. - Android: scan barcode, and follow the prompts.
- iOS: press
NOTE: to run on mobile device, your development machine & device must be on the same WiFi network.
There are several different methods of debugging & obtaining logs while developing. These methods are outlined here: https://facebook.github.io/react-native/docs/debugging.html. We have some of these dependencies installed in the project for convenience.
- Launch standalone React DevTools:
npm run devtools
- Accessing Console Logs:
react-native log-ios
react-native log-android
Starts the app in the simulator with REACT_NATIVE_EXPLORER_DEBUG=1
. This configures the app to hit our explorer services on localhost
instead of the remote hosts used in normal "development" mode.
NOTE: You must be running the services (explorer-api
, explorer-gps
, exploer-messenger
) on localhost
to use this mode.
npm run ios-debug
npm run android-debug
npm run test
npm run lint
You can find some helpful information about performing some common tasks in this
ReactNative environment in the REACTNATIVE.md
file in this repository.