0.0.1 • Published 5 years ago
capacitor-iap v0.0.1
Capacitor Camera Preview
Capacitor plugin that allow to use in app purchase.
Installation
yarn add capacitor-iap
or
npm i capacitor-iapiOS Quirks
Create a Products.plist file on ios/App/App with the following content:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<array>
<string><!-- product id 1--></string>
<string><!-- product id 2--></string>
</array>
</plist>Web Quirks
Add import 'capacitor-iap' to you entry script.
Methods
canMakePayments()
Checks if can make payments
return
| key | type | description |
|---|---|---|
| canMakePayments | boolean | Indicates id can make payments |
getProducts()
Retrive products information
return
| key | type | description |
|---|---|---|
| products | array | A list of store products |
eg.
[{
"currency": "USD",
"description": "Some description - localized",
"price": 49.99,
"productIdentifier": "<product identifier>",
"title": "Product title - localized"
}]0.0.1
5 years ago