Question

Paywall on purchase start callback

  • 28 March 2024
  • 0 replies
  • 19 views

Badge

Hi, I’m using Paywalls feature in my SwiftUI App. I want to disable Paywall interactions while purchase is in progress, is there onPurchaseStart callback or something? here is my current implementation:

                .sheet(isPresented: $userViewModel.displayPayWall) {
PaywallView(displayCloseButton: true)
.onPurchaseCompleted({ userInfo in
print("completed")
userViewModel.isPurchasing = false
userViewModel.isSubscriptionActive = userInfo.entitlements["pro"]?.isActive ?? false
})
.interactiveDismissDisabled(userViewModel.isPurchasing)
}

 


This post has been closed for comments