build universal cross-platform apps with react native
Web | ||
---|---|---|
Android | ||
macOS | ||
- ReNative
0.28.0
or newer - Node
10.13.0
or newer - NPM
6.4.1
or newer - Android Studio (if you want to develop for Android)
- Xcode (if you want to develop for iOS/tvOS)
-
Create Firebase project: https://firebase.google.com/docs/storage/web/start
-
Get your Firebase config file or object: https://support.google.com/firebase/answer/7015592
rnv
will create Firebase config file at this location: <your-project>/projectConfig/firebase.js
Open the file and edit Firebase configuration with:
const config = {
apiKey: '<your-api-key>',
authDomain: '<your-auth-domain>',
databaseURL: '<your-database-url>',
projectId: '<your-cloud-firestore-project>',
storageBucket: '<your-storage-bucket>',
messagingSenderId: '<your-sender-id>',
appId: '<your-app-id>',
};
Web | ||
---|---|---|
- Supports Chrome, Safari, Firefox, IE10+
- no extra requirements required
Feature | Version |
---|---|
Webpack | 3.11.0 |
react-native-web | 0.9.1 |
Babel Core | 7.1.2 |
rnv run -p web
RNV will run local server and attempt to open browser URL: http://0.0.0.0:8080/
If you only want to run server:
rnv start -p web
rnv build -p web
your deployable web app folder will be located in ./platformBuilds/<APP_ID>_web/public
Clean and Re-build platform project
rnv run -p web -r
Run with verbose logging:
rnv run -p web --info
Run app on custom port 9999
:
rnv run -p web --port 9999
Android | ||
---|---|---|
- Latest Android project
- Kotlin Support
- Support for Gradle 4.9
- Android Studio for Android development
- Android SDK
23.0.1
or newer for Android development
Feature | Version |
---|---|
Gradle | 4.10.1 |
Android Gradle | 3.3.1 |
Kotlin | 1.3.20 |
Target SDK | 27 |
You can create variety of emulators via Android Studio IDE
NOTE: make sure you have 1 android device connected or 1 emulator running
rnv start
rnv run -p android
rnv start
rnv run -p android -d
This will run production version on your device (not connected to metro bundler)
You can configure each buldScheme
ie -s release
in your config file ./appConfigs/<YOUR_APP_CONFIG>/config.json
rnv start
rnv run -p android -s release -d
Clean and Re-build platform project
rnv run -p android -r
Launch specific android emulator:
rnv target launch -p android -t Nexus_5X_API_26
Launch app with specific iOS simulator (let ReNative to give you the list of available options):
rnv run -p android -t ?
Launch specific emulator :
rnv target launch -p android -t Nexus_5X_API_26
Launch specific emulator (let ReNative to give you the list of available options):
rnv target launch -p android -t ?
Get list of all available devices
rnv target list -p android
Get device/simulator logs
rnv log -p android
Get device/simulator logs with filter
rnv log -p android -f com.myapp
macOS | ||
---|---|---|
- support for OSX/macOS
- Based on Electron
- n/a
Feature | Version |
---|---|
electron | 2.0.0 |
react-native-web | 0.9.9 |
electron-builder | 20.28.2 |
rnv run -p macos
This will run production version on your simulator (not connected to devserver)
You can configure each buldScheme
ie -s release
in your config file ./appConfigs/<YOUR_APP_CONFIG>/config.json
rnv run -p macos -s release