Skip to main content
Question

Presentations are not currently supported in Volumetric contexts

  • February 17, 2024
  • 0 replies
  • 288 views

Forum|alt.badge.img+2

I’m trying to integrate the paywall into my VisionOS app, which creates a volumetric WindowGroup. When the paywall attempts to present itself, I get the error “Presentations are not currently supported in Volumetric contexts.” 

Using Xcode 15.3 Beta 3 with Apple Vision Pro (1.1) simulator. 

import SwiftUI
import RevenueCat
import RevenueCatUI

@main
struct Sheila_VisionOSApp: App {
    init() {
        Purchases.logLevel = .debug
        Purchases.configure(withAPIKey: "XXXXXXXX", appUserID: nil)
    }

    var body: some Scene {
        WindowGroup {
            SheilaAppView()
                .presentPaywallIfNeeded(
                    requiredEntitlementIdentifier: "access",
                    purchaseCompleted: { customerInfo in
                        print("Purchase completed: \(customerInfo.entitlements)")
                    },
                    restoreCompleted: { customerInfo in
                        // Paywall will be dismissed automatically if "pro" is now active.
                        print("Purchases restored: \(customerInfo.entitlements)")
                    }
                )
        }.windowStyle(.volumetric)
    }
}

 

This post has been closed for comments

Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings