Dans le nouveau xCode 9.0: J'ai simplement essayé de charger une chaîne HTML dans webView (WKWebView) mais j'ai reçu un écran vide! La chose étrange est le même code fonctionne dans mon autre ordinateur!WKWebView ne présente pas la chaîne HTML dans Mac OSX
Est-ce un bug?
Voici le code
let filePath = Bundle.main.path(forResource: "my HTML file name", ofType: "html")
let htmlStr = try! NSString.init(contentsOfFile: filePath!, encoding: String.Encoding.utf8.rawValue)
webView.loadHTMLString(htmlStr as String, baseURL: nil)