commands
Listens for the user executing commands registered using the commands
manifest.json key.
Also provides features to update the shortcut key settings. See Updating shortcuts in the commands
manifest.json key guide for more information.
Types
commands.Command
Object containing a command's settings.
Functions
commands.getAll
Gets all registered commands for the extension.
commands.openShortcutSettings
Opens the Manage Extension Shortcuts page, highlighting the extension's shortcut options, if it has any.
commands.reset
Resets a command's description and shortcut to the values given in the manifest key.
commands.update
Changes the description or shortcut for a command.
Events
commands.onChanged
Fired when the keyboard shortcut for a command is changed.
commands.onCommand
Fired when a command is executed using its associated keyboard shortcut.
Example extensions
Browser compatibility
Note: This API is based on Chromium's chrome.commands
API.