fn
runKeydown
Look up and run the command bound to a keydown event. Returns `true` when a command handled it (the caller should then `preventDefault`).
Signature
ts
export function runKeydown(
event: KeyboardEvent,
compiled: Map<string, Command>,
state: EditorState,
dispatch: Dispatch,
view: CommandView,
): boolean{ ... }Parameters
| Parameter | Type | Description |
|---|---|---|
event | KeyboardEvent | — |
compiled | Map<string, Command> | — |
state | EditorState | — |
dispatch | Dispatch | — |
view | CommandView | — |
Returns
boolean