yarn
For iOS, do the following:
cd ios
pod install
cd -
First start the metro server:
yarn start
You can then either build for iOS:
yarn ios
or for Android with 2 variants: play
or amazon
.
yarn android:play
yarn android:amazon
To be able to get products/subscriptions from the App Store or Play Store you will need to follow a few steps:
Go to developer.apple.com
- Open "Certificates, Identifiers & Profiles" > "Identifiers"
- Click the "Plus" button
- Select "App IDs", continue, select "App"
- Complete the form and submit:
- Description: React Native IAP Example
- Bundle ID (explicit): org.reactjs.native.example.IapExample
- Click "Register"
- Create a new app:
- Platforms: iOS
- Name: React Native IAP Example <SOME_STRING>
- Sku: reactnativeiapexample
- Go to "In-App Purchases", click "Create"
- Select "Consumable" and submit:
- Reference Name: com.cooni.point1000
- Product ID: com.cooni.point1000 (can be the value defined in utils/constants.ts)
- Go back to the app, login with your account when the AppStore shows you the prompt
- Voilà!
If you want more advanced one please refer to dooboolab.com/sponsor.tsx
In order to get products and subscriptions.