No extra coding, just change some configs.
src-tauri/tauri.conf.json
{
...
"app": {
"windows": [
{
...
"zoomHotkeysEnabled": true
}
],
},
...
}
src-tauri/capabilities/default.json
{
...
"permissions": [
...
"core:webview:allow-set-webview-zoom"
]
}
This is a pretty new feature and not yet well documented in the official docs. The VS Code plugin and config schema can be helpful.