fn
chainCommands
testedCombine commands into one that runs them in order and stops at the first that applies (returns `true`). The standard way to bind several fallbacks to a key.
Signature
ts
export function chainCommands(...commands: readonly Command[]): Command{ ... }Parameters
| Parameter | Type | Description |
|---|---|---|
commands? | readonly Command[] | — |
Returns
Command