How to get scalesPageToFit behaviour for HTML content displayed in a WKWebView without using JavaScript? (disabling JS is a requirement for in our case).
Sorry for not posting any code, but I have no idea how I could achieve this. All solutions I know and all I found are based on JS. Example.
I already add <meta name="viewport" content="width=device-width, initial-scale=1.0"/> to the HTML if it does not exist yet, but at least images are often displayed way too big.
All images are provided to WKWebView by a WKURLSchemeHandler.
Please put
<meta name="viewport" content="initial-scale=1.0" />
inside your <head> tag.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With