Created
January 12, 2026 03:58
-
-
Save arpit/31aad30d67cccc50663c8605616b7340 to your computer and use it in GitHub Desktop.
Offsets the content of a webview
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| func makeUIView(context: Context) -> WKWebView { | |
| let webView = WKWebView() | |
| webView.navigationDelegate = context.coordinator | |
| webView.scrollView.contentInset = UIEdgeInsets(top: ArticleWebView.webviewContentOffset, left: 0, bottom: 0, right: 0) | |
| webView.scrollView.verticalScrollIndicatorInsets = UIEdgeInsets(top: ArticleWebView.webviewContentOffset, left: 0, bottom: 0, right: 0) | |
| return webView | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment