Set WebView baseURL to 'about:blank' instead of nil
Reviewed By: javache Differential Revision: D2953831 fb-gh-sync-id: 2b11353ee453711f32e19011c13d89c128fa16ab shipit-source-id: 2b11353ee453711f32e19011c13d89c128fa16ab
This commit is contained in:
parent
4b97137eee
commit
f961b78c51
|
@ -80,6 +80,9 @@ RCT_NOT_IMPLEMENTED(- (instancetype)initWithCoder:(NSCoder *)aDecoder)
|
|||
NSString *html = [RCTConvert NSString:source[@"html"]];
|
||||
if (html) {
|
||||
NSURL *baseURL = [RCTConvert NSURL:source[@"baseUrl"]];
|
||||
if (!baseURL) {
|
||||
baseURL = [NSURL URLWithString:@"about:blank"];
|
||||
}
|
||||
[_webView loadHTMLString:html baseURL:baseURL];
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue