API reference

Every public class, method, and event in @codexo/exojs. Generated from source.

T

typeInputToken

@codexo/exojs / input / stable

Stable, persistable identifier for one input control. A token is lowercase ASCII, uses `.` as the namespace separator and `-` inside a name: `keyboard.space`, `keyboard.key-w`, `pointer.primary`, `gamepad.button.south`, `gamepad.axis.left-stick-x`. Tokens are the only representation of a control that may be written to disk or sent over a network. They deliberately carry no gamepad slot, no browser device index, no enum number, no vendor name and no localized label: a slot is runtime context (see ActionMapOptions.gamepad), and everything else would change meaning between builds, browsers or players. Keyboard tokens are the kebab-cased `KeyboardEvent.code` of the physical key, so `keyboard.key-w` is the key an AZERTY keyboard prints "Z" on - the same layout-independent identity Keyboard itself uses. The four aggregate modifier channels have no `code` of their own and take the unsided name (`keyboard.shift`).

0
props
0
methods
0
events
Import
import { InputToken } from '@codexo/exojs'

Stable, persistable identifier for one input control.

A token is lowercase ASCII, uses `.` as the namespace separator and `-` inside a name: `keyboard.space`, `keyboard.key-w`, `pointer.primary`, `gamepad.button.south`, `gamepad.axis.left-stick-x`.

Tokens are the only representation of a control that may be written to disk or sent over a network. They deliberately carry no gamepad slot, no browser device index, no enum number, no vendor name and no localized label: a slot is runtime context (see ActionMapOptions.gamepad), and everything else would change meaning between builds, browsers or players.

Keyboard tokens are the kebab-cased `KeyboardEvent.code` of the physical key, so `keyboard.key-w` is the key an AZERTY keyboard prints "Z" on - the same layout-independent identity Keyboard itself uses. The four aggregate modifier channels have no `code` of their own and take the unsided name (`keyboard.shift`).

Definition1
string
Source