Definition
Gamepad defines Gamepad
[Exposed=Window]
interface Gamepad {
readonly attribute DOMString id;
readonly attribute long index;
readonly attribute boolean connected;
readonly attribute DOMHighResTimeStamp timestamp;
readonly attribute GamepadMappingType mapping;
readonly attribute FrozenArray<double> axes;
readonly attribute FrozenArray<GamepadButton> buttons;
readonly attribute FrozenArray<GamepadTouch> touches;
[SameObject] readonly attribute GamepadHapticActuator vibrationActuator;
};
Methods and attributes that return objects implementing Gamepad
Referring IDL interfaces/dictionaries
Referring specifications
- WebXR Gamepads Module - Level 1 refers to
Gamepad