StoreKit's ProductView, StoreView, and SubscriptionStoreView under One.iOS
StoreKit’s merchandising views under One.iOS. StoreKit loads each product
from the App Store, draws its name, price, and buy button, and runs the
purchase sheet when the person taps it.
.ios.tsx file.To list products, buy them, and read entitlements from code, use Purchases.
import { One } from 'one'
<One.iOS.ProductView id="com.example.coins.100" /><One.iOS.SubscriptionStoreView groupID="21482456" style={{ height: 420 }} />One product with its icon, name, description, and buy button.
| Props | Type | Description |
|---|---|---|
id (required)stringThe product identifier. | string | The product identifier. |
prefersPromotionalIconboolean = falseUses the promotional image from App Store Connect as the icon. | boolean = false | Uses the promotional image from App Store Connect as the icon. |
A list of products, each drawn as a ProductView.
| Props | Type | Description |
|---|---|---|
ids (required)readonly string[]The product identifiers, in display order. | readonly string[] | The product identifiers, in display order. |
prefersPromotionalIconboolean = falseUses each promotional image as its icon. | boolean = false | Uses each promotional image as its icon. |
The subscription store for one group of auto-renewable subscriptions. Pass
exactly one of groupID and productIDs; both or neither throws. Give it a
height, since it fills the box React Native gives it.
| Props | Type | Description |
|---|---|---|
groupIDstringThe subscription group identifier. | string | The subscription group identifier. |
visibleRelationships"current" | "downgrade" | "crossgrade" | "upgrade" | "all" = "all"Which plans to show relative to the current one. Only with groupID; it throws with productIDs. | "current" | "downgrade" | "crossgrade" | "upgrade" | "all" = "all" | Which plans to show relative to the current one. Only with groupID; it throws with productIDs. |
productIDsreadonly string[]The subscription product identifiers to show. | readonly string[] | The subscription product identifiers to show. |
The binding uses ProductView(id:prefersPromotionalIcon:),
StoreView(ids:prefersPromotionalIcon:), and the SubscriptionStoreView
groupID:visibleRelationships: or productIDs: initializers. The SDK
specializes these overloads to its default icon and marketing views.
Overloads accepting StoreKit.Product objects, icon builders or marketing
content are not bound. Their arguments include native product values and
callbacks returning generic SwiftUI views, which this generated constructor
bridge cannot carry. Pass catalog identifiers to the bound overloads.
Xcode’s local StoreKit configuration can exercise catalog rendering on the simulator without an account or real payment. That test catalog does not establish App Store catalog availability, purchases, subscription eligibility or entitlements for a signed app and account.
Edit this page on GitHub.