Home
Project

Migrating from the earlier names

The rename mapping for code written against the first, Cabinet-prefixed API.

Before its first npm release the package used a Cabinet prefix for its React, pause and UI exports. Those names described one particular host app rather than what the exports do, so they were renamed to neutral ones before 0.1.0. Only names, one prop, a few strings and the DOM hooks changed; behavior is identical.

If you used the earlier API from a git checkout or a private registry, update imports from the old package name to game-session and apply the mapping below.

Exports

Earlier nameName nowEntry point
useCabinetRuntimeuseGameRuntimegame-session/react
UseCabinetRuntimeOptionsUseGameRuntimeOptionsgame-session/react
readCabinetSettingsreadGameSettingsgame-session/react
writeCabinetSettingswriteGameSettingsgame-session/react
setCabinetRuntimePausedsetGameRuntimePausedgame-session
isCabinetRuntimePausedisGameRuntimePausedgame-session
clearCabinetRuntimePausedclearGameRuntimePausedgame-session
CabinetPauseChangeDetailGamePauseChangeDetailgame-session
CabinetMenuButton, CabinetMenuButtonPropsGameMenuButton, GameMenuButtonPropsgame-session/ui
CabinetPauseMenu, CabinetPauseMenuPropsGamePauseMenu, GamePauseMenuPropsgame-session/ui
CabinetSettingsPanel, CabinetSettingsPanelPropsGameSettingsPanel, GameSettingsPanelPropsgame-session/ui
CabinetErrorBoundary, CabinetErrorBoundaryPropsGameErrorBoundary, GameErrorBoundaryPropsgame-session/ui

Everything else (beginGameRun, finishGameRun, GameSettings, RuntimeResultRecorder, SessionMode, ...) kept its name.

Props

ComponentEarlier propProp now
GamePauseMenuonCabinetonMainMenu
GameErrorBoundaryonReturnToCabinetonReturnToMenu
GamePauseMenu(a fixed header line naming the host app)optional eyebrow string, rendered above the title only when given

Visible text

WhereEarlier textText now
Pause menu actionCabinetMain Menu
Error boundary heading and buttonReturn To CabinetReturn To Menu
Error boundary body"This cartridge failed to start cleanly...""This game failed to start cleanly..."
Menu button default titleOpen cabinet menuOpen game menu

DOM hooks

HookEarlierNow
Pause attribute on <html>data-cabinet-paused (dataset.cabinetPaused)data-game-paused (dataset.gamePaused)
Text-scale custom property--cabinet-text-scale--game-text-scale
Joystick custom property--cabinet-joystick-sensitivity--game-joystick-sensitivity
Menu button test idcabinet-menu-buttongame-menu-button
Pause menu test idcabinet-pause-menugame-pause-menu
Settings panel test idcabinet-settings-panelgame-settings-panel
Rules panel test idcabinet-rules-panelgame-rules-panel

Unchanged on purpose

The default storage namespace game-session:v1 and the window event game-session:pause-change are neutral and stay as they are, so progress already stored under the default namespace keeps loading.

Stored data written under an app-specific namespace is untouched: pass the same namespace you used before.