pub fn devtools_shortcut_script() -> StringAvailable on debug-assertions enabled or crate feature
devtools only.Expand description
The page script that binds the DevTools keyboard shortcut - Ctrl+Shift+I, or
Cmd+Alt+I on macOS - to the webview plugin’s internal_toggle_devtools command.
It is up to each runtime to inject this into the webviews it creates, and only into the ones that have no shortcut of their own:
tauri-runtime-wryinjects it always. None of the webviews it drives - WebView2, WKWebView, WebKitGTK - binds the chord itself.tauri-runtime-cefinjects it only into Alloy style browsers. A Chrome style one already dispatchesIDC_DEV_TOOLSfor the same chord, and with both in place the toggle closes the window the accelerator just opened.
Returns the script with its one template value resolved for the target this crate was compiled for.