I have a standalone watchOS 7 app and want to implement handoff for a URL the user can open on their browser.
Nothing happens, and the update block is not even executed.
Here's the relevant code, with the URL removed:
And the Info.plist for the WatchKit App:
Am I doing anything wrong here?
Nothing happens, and the update block is not even executed.
Here's the relevant code, with the URL removed:
Code Block swift import SwiftUI @main struct MyApp: App { @SceneBuilder var body: some Scene { WindowGroup { NavigationView { ContentView() } .userActivity( "MyAppBundleId.watchkitapp.install-plugin", isActive: true ) { activity in activity.isEligibleForHandoff = true activity.webpageURL = URL(string: "[redacted]") } } } }
And the Info.plist for the WatchKit App:
Code Block xml <key>NSUserActivityTypes</key> <array> <string>MyAppBundleId.watchkitapp.install-plugin</string> </array>
Am I doing anything wrong here?