Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

Gamepad

This Gamepad API interface defines an individual gamepad or other controller, allowing access to information such as button presses, axis positions, and id. Available only in secure contexts.

interface Gamepad {
readonly axes: ReadonlyArray<number>;
readonly buttons: ReadonlyArray<GamepadButton>;
readonly connected: boolean;
readonly hapticActuators: ReadonlyArray<GamepadHapticActuator>;
readonly id: string;
readonly index: number;
readonly mapping: GamepadMappingType;
readonly timestamp: DOMHighResTimeStamp;
}
var Gamepad: {
prototype: Gamepad;
new (): Gamepad;
}
;

§Properties

§
readonly axes: ReadonlyArray<number>
[src]
§
readonly buttons: ReadonlyArray<GamepadButton>
[src]
§
readonly connected: boolean
[src]
§
readonly hapticActuators: ReadonlyArray<GamepadHapticActuator>
[src]
§
readonly id: string
[src]
§
readonly index: number
[src]
§
readonly mapping: GamepadMappingType
[src]
§
readonly timestamp: DOMHighResTimeStamp
[src]