UIWebview調用reload導致JSContext失效
UIWebViewDelegate
1、webView(_ webView: UIWebView, shouldStartLoadWith request: URLRequest, navigationType: UIWebViewNavigationType) -> Bool
2、webViewDidStartLoad
3、webViewDidFinishLoad
4、didFailLoadWithError
當頁面刷新或者跳轉新頁面,shouldStartLoadWith與webViewDidStartLoad獲取的均爲上一個頁面的JSContext。而webviewDisFinishLoad觸發的時候,獲取雖然是正確的JSContext,但是此時頁面已經加載完畢,js方法已經調用完了,獲取到正確的值也沒用了