方法一 跳入外部浏览器
guard let url = URL(string: "https://www.baidu.com") else { return }
UIApplication.shared.open(url)
方法二 app内部打开
import SafariServices
func openBrowse() {
guard let url = URL(string: "https://www.baidu.com") else { return }
let safariVC = SFSafariViewController(url: url)
showDetailViewController(safariVC, sender: nil)
}