You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Oct 20, 2020. It is now read-only.
* Add support for React Native 29+
* Add instructions for RN 29 to Readme. Update rnpm link in package.json. Add back InAppBillingBridgePackage with no arguments. Update target React Native compilation dependency.
* Use getCurrentActivity method everywhere instead of keeping a reference to an activity.
Copy file name to clipboardExpand all lines: README.md
+69-48Lines changed: 69 additions & 48 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -43,59 +43,80 @@ With this, [rnpm](https://github.com/rnpm/rnpm) will do most of the heavy liftin
43
43
}
44
44
```
45
45
46
-
4. Edit `MainActivity.java`. Step 4.3 is only required if you are using a lower React Native version than 18.0 and/or your `MainActivity` class does not inherit from `ReactActivity`.
Edit `MainActivity.java`.Step4.3 is only required if you are using a lower ReactNative version than 18.0 and/or your `MainActivity` classdoes not inherit from `ReactActivity`.
5.Add your GooglePlay license key as a line to your `android/app/src/main/res/values/strings.xml` with the name `RNB_GOOGLE_PLAY_LICENSE_KEY`.For example:
If you want to test with static responses, you can use reserved productids defined by Google. These are:
101
122
* android.test.purchased
@@ -113,7 +134,7 @@ In order to do this send in `null` as parameter, along with your Activity-instan
113
134
[See the Google Play docs for more info on static responses](http://developer.android.com/google/play/billing/billing_testing.html#billing-testing-static).
114
135
115
136
## Testing with your own In-app products
116
-
Testing with static responses is limited, because you are only able to test the `purchase` function. Therefore, testing with real In-app products is recommended. But before that is possible, you need to do the following:
137
+
Testing with static responses is limited, because you are only able to test the `purchase` function. Therefore, testing with real In-app products is recommended. But before that is possible, you need to do the following:
117
138
* I will assume you've already created your Google Play Developer account and an application there.
118
139
* Now you need to create an In-app product under your application at the GooglePlayDeveloperConsole and activate it (pressthebuttonatthetopright).
119
140
* Assuming you have installed this module (InAppBilling), you can write the JS code as explained in the Javascript API section. I suggest you to use `getProductDetails` function to see if it's the product is retrieved.
@@ -123,7 +144,7 @@ Testing with static responses is limited, because you are only able to test the
123
144
* The final part is, you'll need to add testers for the channel you've published to. The web page will give you a signup URL (opt-in) after you've approved open testing. Visit this URL in the browser of your **testing device** (it must be a physical device, not a emulator) and signup, and download the app where it redirected.
124
145
* Try to buy something with the device. The purchase will eventually be cancelled, but you can also do this manually through your Google Merchant wallet.
125
146
126
-
**Important**: You can only test on a physical Android device, not from an emulator.
147
+
**Important**: You can only test on a physical Android device, not from an emulator.
0 commit comments