I managed to fix the problem with (ObjC / Swift):
if (@available(iOS 11.0, *)) {
webView.scrollView.contentInsetAdjustmentBehavior = UIScrollViewContentInsetAdjustmentNever;
}
or
if
webView.scrollView.contentInsetAdjustmentBehavior = .never;
}
This parameter seems to have the same effect as viewport-fit=cover
, therefore, if you know that your content uses this property, you can fix the error as follows.
CSS- env(safe-area-inset-top)
. WKWebView , , .
contentInsetAdjustmentBehavior @dpogue , .