Limited Availability
id: keyboard-map
Keyboard map
The
navigator.keyboard.getLayoutMap() API returns a map from key codes to human readable key names. It can be used to describe buttons to the user when using the keyboard as a set of buttons, such as in games.
Baseline Status:
This feature is currently Limited and is missing in at least one major browser engine.
Desktop Browser Engine Support
Google Chrome
69
Supported
Mozilla Firefox
—
Unsupported
Apple Safari
—
Unsupported
Microsoft Edge
79
Supported
Mobile Browser Engine Support
Chrome Android
69
Firefox Android
—
Safari iOS
—
Specifications and References
MDN Browser Compat Data Keys:
api.Keyboard.getLayoutMap ↗
api.KeyboardLayoutMap ↗
api.KeyboardLayoutMap.@@iterator ↗
api.KeyboardLayoutMap.entries ↗
api.KeyboardLayoutMap.forEach ↗
api.KeyboardLayoutMap.get ↗
api.KeyboardLayoutMap.has ↗
api.KeyboardLayoutMap.keys ↗
api.KeyboardLayoutMap.size ↗
api.KeyboardLayoutMap.values ↗