This is a follow up to my previously asked question about trackpad based zooming in Chromium based browsers, but it's a different question.
I want to programmatically set the zoom level in a browser window. This seems to be a common demand, as some prior (very old though) questions show:
- imitate browser zoom with JavaScript
- Changing the browser zoom level
- How to detect page zoom level in all modern browsers?
However all those questions seem to get answers suggesting to set body.style.zoom
or body.style.transform
. But this seems to be a different thing, e.g. the zoom level indicated in the navigation bar does not change, elements are being drawn differently and after a reload these settings are gone.
So - risking down-votes for redundantly asking questions - in 2023 is there a way (at least in Chromium based browsers) to set the zoom level as indicated in the navigation bar programmatically (i.e. in JavaScript)?