Anders Back a1056e175e Support For Multi Target Applications (#66)
* CONFIGURATION_BUILD_DIR => BUILD_DIR

* support for react native 0.40
2017-04-26 15:00:07 -07:00
..
2016-09-13 18:39:29 -07:00
2016-09-13 18:39:29 -07:00
2016-03-03 13:32:22 -08:00
2016-03-03 13:32:22 -08:00
2016-09-13 18:39:29 -07:00
2016-09-13 18:39:29 -07:00
2016-02-22 12:54:52 -08:00
2016-09-13 18:39:29 -07:00
2016-11-28 15:08:05 -08:00

Example app using react-native-config

Just a single app accessing config variables from .env and .env.prod.

Running in Android

By default it will read variables from .env:

$ react-native run-android

To read from another file just specify it with ENVFILE, like:

$ ENVFILE=.env.prod react-native run-android

Running in iOS

Open the Xcode project file in Example/ios/Example.xcodeproj.

Notice there are two schemes setup for the application: "Example" runs the default build, reading vars from .env  and "Example (prod)" is configured to read from .env.prod.