@livx.cc/appwrap 0.23.1 → 0.23.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@livx.cc/appwrap",
3
- "version": "0.23.1",
3
+ "version": "0.23.2",
4
4
  "description": "Wrap any PWA into a native app with native capabilities (appwrap runtime + @livx.cc/native-kit).",
5
5
  "license": "MIT",
6
6
  "author": "Elya Livshitz",
@@ -167,6 +167,14 @@ export function registerBillingHandlers(): void {
167
167
 
168
168
  bridge.register('billing.restore', () => restoreTransactions());
169
169
 
170
+ // The bundle's App Store receipt, read straight from disk — NO Apple-ID prompt and no
171
+ // store round-trip (unlike restore). For an in-place app update it already holds the
172
+ // user's active/grandfathered subscriptions, so a server validator can confirm
173
+ // entitlements silently. This is the zero-user-action path for migrating existing
174
+ // subscribers into a new build of the SAME bundle id. Empty string if absent (e.g. a
175
+ // dev build with no receipt) — the caller falls back to restore().
176
+ bridge.register('billing.appReceipt', async () => ({ platform: 'ios', appReceipt: appReceipt() }));
177
+
170
178
  // Client-trusted entitlements: StoreKit 1 has no on-device entitlement list, so we
171
179
  // derive non-consumed/active products from a restore. Real apps plug in a server
172
180
  // validator (see kit.billing.configure) instead of trusting this.