Trigger shortcut in a Chrome extension
问题 I am building a Chrome extension, and assigned command _execute_browser_action to Alt + J . I want to simulate this in background.js which listens for all commands using chrome.commands.onCommand.addListener(function(command) { /* ... */ }); I want _execute_browser_action to be called through a different command shortcut, say Cmd + Shift + K In my manifest.json I have declared the following: "commands": { "_execute_browser_action": { "suggested_key": { "mac": "Alt+J", "linux": "Ctrl+Shift+J"