fix(iOS): webview retain cycle (#1916)
Co-authored-by: sunzhongliang <sunzhongliang@innotechx.com>
This commit is contained in:
parent
099087f8d9
commit
30a53d9480
|
@ -331,6 +331,7 @@ static NSDictionary* customCertificatesForHost;
|
|||
- (void)removeFromSuperview
|
||||
{
|
||||
if (_webView) {
|
||||
[_webView.configuration.userContentController removeScriptMessageHandlerForName:HistoryShimName];
|
||||
[_webView.configuration.userContentController removeScriptMessageHandlerForName:MessageHandlerName];
|
||||
[_webView removeObserver:self forKeyPath:@"estimatedProgress"];
|
||||
[_webView removeFromSuperview];
|
||||
|
|
Loading…
Reference in New Issue