SHIFT + D

keycombo match

Updated on August 22, 2024Source codeTests

createKeycomboMatch is a pipe that transforms a keyboard event descriptor to a boolean indicating whether or not the event matches a given keycombo.

A keyboard event descriptor is an object with code, shiftKey, altKey, ctrlKey, and metaKey properties, all of which are optional. This means your keycomboMatch function works not only with keyboard events, but also mouse, pointer, and touch events.

Create keycombo match

Call createKeycomboMatch with these parameters to create your keycomboMatch function:

Parameter
Type
Required
Description
keycombo
yes
The keycombo to match.
options
Object
no
Options to customize the behavior of the keycomboMatch function. See the Options section for more guidance.

Options

createKeycomboMatch accepts the standard options for configuring the keycombo system

insertkeys

Edit doc on GitHub

ON THIS PAGE

keycombo matchCreate keycombo matchOptions