Skip to content

Add support for event.code #92

Description

@theinterned

While it may prove impossible to smooth over all OS / keyboard layout differences in event.key, providing access to mapping hotkeys to an event.code may help in some situations (for example WASD navigation)

VS Code allows this via wrapping the code in []: for example [KeyA] would match on event.code === "KeyA".

This allows for some flexibility to map shortcuts to physical locations on the keyboard (eg WASD navigation etc.)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions