Changelog
Changes to the @gamepadly/sdk package: its API, its runtime behavior and how to migrate. Documentation, examples
and tooling changes are not listed.
The format follows Keep a Changelog. While the SDK is at 0.x, a minor
version (0.x.0) can change behavior, always with migration notes here; a patch version (0.x.y) only fixes bugs.
[Unreleased]
Section titled “[Unreleased]”[0.9.0] - 2026-12-05
Section titled “[0.9.0] - 2026-12-05”- Menu navigation:
actions.repeated(name)is true on the press, then again after a delay and at an interval while the action is held. Set the timing withrepeat: { delayMs, intervalMs }in the action map (default 400 ms and 100 ms).ActionStatehas a matchingrepeatedfield. - Remapping:
actions.getBindings()returns the current bindings as JSON-safe data,actions.setBindings()replaces the bindings of the listed actions and axes, andactions.lastPressed()returns the input that went down in the latest update (a controller button by its position name,'l2'/'r2', a stick direction, a key code or a mouse button). A rebound action stays released until its inputs are let go.setBindings()ignores names the map does not declare. New typeActionBindings. isControllerBinding(binding)tells controller bindings from keyboard and mouse bindings.ignoreHeldOnStartin the action map keeps actions that are held when the map is created released until they are let go.
Changed
Section titled “Changed”getButtonLabel()also labels'l2'and'r2'(LT / L2 / ZL and RT / R2 / ZR), and accepts any binding string, returning names it does not know unchanged.createActionTracker()copies the bindings it is given, sosetBindings()never changes the spec object you passed.
[0.8.0] - 2026-12-05
Section titled “[0.8.0] - 2026-12-05”Changed
Section titled “Changed”hub.player(n)keeps its controller. Before, it read whichever controller was n-th in the connected list at that moment, so when P1 unplugged,hub.player(0)switched to P2’s controller andhub.player(1)went idle. Connecting a DualSense or Switch Pro over WebHID also reordered the list, because WebHID controllers are listed first. Now each numbered player stays on its controller while others connect, disconnect or upgrade to WebHID. A player whose controller disconnects reads an idle state andgetSlotId()returnsnull, and the next controller that connects takes the lowest free player number.createGameHost()withoutgetPlayerSeatsgets the same behavior forsdk.players.get(n).
Migration notes
Section titled “Migration notes”- To detect that a player’s controller is gone, check
hub.player(n).getSlotId() === null, for example to pause the game. - Code that relied on players moving up after a disconnect, such as always reading
hub.player(0)for “whoever is still connected”, should readhub.activeinstead, or pick fromhub.getSlots().
[0.7.0] - 2026-12-04
Section titled “[0.7.0] - 2026-12-04”Changed
Section titled “Changed”createKeyMouseBridge()dispatches keyboard events ondocumentby default, instead ofwindow. Events bubble fromdocumenttowindow, so games that listen on either now work withoutkeyTarget. Before, a game listening ondocumentreceived nothing unless you passedkeyTarget: document. Where there is nodocument, the bridge still useswindow.
Migration notes
Section titled “Migration notes”- A game that handles the same key on both
windowanddocumentnow receives each bridged key on both. PasskeyTarget: windowto keep the old behavior. - A game that listens on an element, such as a focused canvas, still needs
keyTarget: thatElement.
[0.6.0] - 2026-12-04
Section titled “[0.6.0] - 2026-12-04”- Position-based button names. Action maps (
createActions(),createActionTracker()) and bridge profiles acceptsouth,east,west,north,select,startandhomealongside the existing names.southis the bottom face button on every brand: A on Xbox, Cross on PlayStation, B on Nintendo. New exports:BUTTON_ALIASES,resolveButtonName(),ButtonAlias,ButtonInput. getButtonLabel(button, brand)returns the label printed on the player’s controller:'A','Cross'or'B';'RT','R2'or'ZR'.UnifiedInputState.mappingreports the layout the browser gave:'standard','nonstandard','custom','hid'or'none'. For a non-standard layout,getCapabilities()explains why instandard_input.reason.- Custom layouts through
createGamepadly({ gamepadMappings }),new DualSenseControllerManager({ gamepadMappings })andmanager.setGamepadMappings(). They remap buttons, stick axes (optionally inverted) and analog triggers read from buttons or axes. New exports:GamepadMappingRule,GamepadAxisSource,GamepadTriggerSource,InputMapping,DualSenseControllerManagerOptions.
Migration notes
Section titled “Migration notes”- If you build
UnifiedInputStateobjects by hand instead of withcreateEmptyInput(), add the new requiredmappingfield, for examplemapping: 'none'.
[0.5.0] - 2026-12-04
Section titled “[0.5.0] - 2026-12-04”- Every haptic call returns the output it played on, as a
HapticRouteTier:'4ch_vcm','hd_rumble','impulse_triggers','dual_rumble'or'none'. This coversplayer.haptics.pulse(),sweep()andplayPreset(),bridge.triggerHaptic(), and therouteHapticPulse(),routeHapticSweep()androuteTactilePreset()functions. Code that ignores the return value is unaffected. @gamepadly/sdk/linkspeaks Gamepadly Link protocol v1.1 (Link v0.4.0 and later).connectDualSenseViaCompanion()checks Link’s health, asks for a session bound to the page’s origin (Link shows a consent prompt for new origins), then lists devices and opens the haptics socket with that session.- New
minProtocolVersionoption. - New error codes:
'link_outdated','user_denied','consent_timeout','consent_busy'and'origin_not_allowed'. Failed results can carryretryAfterSec. - New exports:
CompanionRequestError,CompanionErrorCode,LINK_RELEASES_URL, andCompanionHealth.originAuthorized.
- New
- The 4-channel audio engine no longer needs a separate
/haptic-worklet.jsfile, which failed with a 404 on other origins and on sub-path hosting. The AudioWorklet ships inside the package and is loaded from ablob:URL. For a Content Security Policy that blocksblob:worklets, host the file yourself and pass its URL tocreateLinkAudio({ workletUrl }).
[0.4.3] - 2026-12-04
Section titled “[0.4.3] - 2026-12-04”Changed
Section titled “Changed”- The DualSense speaker plays at a lower default volume (
dsSpeakerGainValue0.65), matched to Link’s system volume mirroring.
- The audio engine reads Link’s
syncSystemVolumesetting, andsetGains()no longer unmutes a muted output.
[0.4.2] - 2026-12-03
Section titled “[0.4.2] - 2026-12-03”- When a game built on
@gamepadly/sdk/gameor@gamepadly/sdk/loopis open in several tabs, only the tab in front reads input and drives rumble and adaptive triggers. Loops pause in background tabs.
[0.4.1] - 2026-12-03
Section titled “[0.4.1] - 2026-12-03”- In
createGameHost(), PC tones, noise and samples played for a player seat nobody has joined are heard on the PC speakers instead of being dropped.
[0.4.0] - 2026-12-03
Section titled “[0.4.0] - 2026-12-03”@gamepadly/sdk/diagnostics:createControllerTelemetry()with 360° stick circularity in 72 sectors, resting drift and button bounce detection.attachControllerLifecycle(),SlotAutoSwitcher,TriggerFeedbackControllerandcreateMicLevelMeter().- One-call helpers for 4-channel audio:
connectDualSenseViaCompanion(),connectDualSenseViaBrowser()andlaunchLinkViaProtocol().