I wanted to show how to make a SwiftUI app that can easily get updated customer info (when purchases are made) to update the user interface to show the newly unlockd content.
- Listens for
CustomerInfoupdates usingPurchases.shared.customerInfoStream(anAsyncSequence) - Updates a
@StateObjectthat is passed as an environment object to children views ContentViewwill...- Display paywall from current
Offeringif no active entitlements - Show a
Text(unlocked content) if active entitlements - Will update automatically when the customer info environment object is updated
- Display paywall from current