Support Universal Links in iOS WebView apps (open URL triggered by other apps)
“When you support universal links, iOS users can tap a link to your website and get seamlessly redirected to your installed app without going through Safari. If your app isn’t installed, tapping a link to your website opens your website in Safari.” (Apple Documentation)
The WebViewGold Xcode template allows you to configure a link scheme like webviewgold:// which can be triggered from Mail app, Safari app, … and opens the attached link URL in the WebView app. Please download the template and change the scheme to your own app name (like your-app-name:// instead of webviewgold://) in Info.plist:
Afterward, activate the ShowExternalLink option in WebViewController.swift file:
Done! 🙂 Example format: WebViewGold://url?link=https://www.google.com (would open google.com in WebView app).