webView(_:didCreateJavaScriptContext:for:)
Notifies the delegate that a new JavaScript context has been created.
Declaration
optional func webView(_ webView: WebView!, didCreateJavaScriptContext context: JSContext!, for frame: WebFrame!)Parameters
Discussion
If a delegate implements this method along with either webView(_:didClearWindowObject:for:) or webView:windowScriptObjectAvailable:, only webView:didCreateJavaScriptContext:forFrame: will be invoked. This lets the delegate implement multiple versions to maintain backwards compatibility with older versions of WebKit.