Skip to content

v0.1.0 - Initial release

Latest

Choose a tag to compare

@rbuzatto rbuzatto released this 12 Sep 00:49

First public release of react-fresh-key. Declare when a reusable component should reset alongside its definition, or let a descendant reset a subtree.

  • Remount components or subtrees with withRemount, Remount, and the key hooks.
  • Reset one state value while keeping the component mounted with useResettableState.
  • Request resets from descendants with shared or typed boundaries, including named requests and payloads.

Install as a package dependency:

npm install react-fresh-key@0.1.0
# or
pnpm add react-fresh-key@0.1.0

Or copy selected source modules into your project:

npx react-fresh-key@0.1.0 add with-remount

Supports React 16.14 and later, with ESM and CommonJS builds and no runtime dependencies beyond React. Types are checked against React 17, 18, and 19. Copied JSX modules require the automatic JSX transform.

Documentation and examples · Changelog · npm package