There are several possible reasons why the SKOverlay may not launch the App Store when using UIKit in an App Clip. Here are some troubleshooting steps you can take to resolve the issue:
if #available(iOS 14.0, *) {
if let scene = UIApplication.shared.delegate?.window??.windowScene {
let _ = SKOverlay.supported()
let session = SKOverlaySceneSession(scene: scene)
}
}
if #available(iOS 14.0, *) {
if SKOverlay.isSupported() {
// SKOverlay is supported in user's region
} else {
// SKOverlay is not supported in user's region
}
}
if UIApplication.shared.canOpenURL(URL(string: "itms-apps://")!) {
// App Store is installed
} else {
// App Store is not installed
}
let productViewController = SKOverlay.appStoreProductViewController()
if productViewController == nil {
// User has restrictions on launching the App Store app
} else {
// User can launch the App Store app
}
class ViewController: UIViewController, SKOverlayDelegate {
...
func overlay(_ overlay: SKOverlay, didFinishDismissalWith response: SKOverlay.Response) {
// Debug errors here
...
}
...
}
By following these troubleshooting steps, you should be able to resolve any issues with SKOverlay in your App Clip.
Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss
Asked: 2023-07-12 01:15:30 +0000
Seen: 8 times
Last updated: Jul 12 '23
What could be the reason for the node app not functioning on Namecheap hosting?
How does rate limiting work for Azure Function in .NET 7?
How to identify the screen location of the mouse pointer in an electron app?
What is missing since the androidmanifest.xml file is not present?
When attempting to launch my Android app, why does my AVD open YouTube instead?
How can I set up a subdomain for Apple app site association?