`struct OpenMainAppIntent: AppIntent {
static let title: LocalizedStringResource = "OpenMainAppIntent"
static var openAppWhenRun: Bool = true
init() {}
@MainActor
func perform() async throws -> some IntentResult & OpensIntent {
guard let url = URL(string: "myapp://open") else {
throw OpenURLError.invalidURL
}
return .result(opensIntent: OpenURLIntent(url))
}
} ` This is an action in my custom control widget, and i want to use this deeplink open my application and get the link's info, but it won't perform onOpenURL
`@main
struct TestControlWidgetApp: App {
var body: some Scene {
WindowGroup {
ContentView()
.onOpenURL { url in
print("url: \(url)")
}
}
}
}`