1.0.4 • Published 5 years ago
@vouched.id/react-native-vouched v1.0.4
Getting started with example project
Example project is located in example
directory.
Is is build from a blank RN project with steps outlined in using.md
(you do not need to repeat them to get
started with example project).
To launch example, after checking out sources, you need to:
1. Download models and link them to the XCode project
Download model files inference_graph.tflite
and labelmap_mobilenet_card.txt
and
place them in example/ios/Models
directory and in example/android/app/src/main/assets
.
Make sure files are added to XCode example project, including Models directory.
2. APP ID
Get your Vouched App ID, and set it in example/env.json
{
"APP_ID": "<PUBLIC KEY - APP_ID>"
}
2 (cnt). Firebase
Add Google Services.plist and google-services.json
- Add GoogleService-Info.plist to example/ios/example
- Add google-services.json to example/android/app
3. Install example dependencies
cd example
yarn install
cd ios
pod install
4. Build and install IOS app
cd example; yarn start
- Open
example/ios/example.xcworkspace
in Xcode - Set the signing capabilities in Targets / example / Signing & Capabilities
- Connector your phone, select it in XCode, and run the app.
5. Build and install Android app
cd example; yarn start
cd example; yarn android
Development workflow
After each change in library, to get updates in example, you need to
yarn install
yarn build
- Stop example bundler
cd example; rm -fr ./node_modules/react-native-vouched
yarn add react-native-vouched@file:../
- Start example bundler.
- Restart app.