Skip to content

Version Packages#612

Open
github-actions[bot] wants to merge 1 commit intomainfrom
changeset-release/main
Open

Version Packages#612
github-actions[bot] wants to merge 1 commit intomainfrom
changeset-release/main

Conversation

@github-actions
Copy link
Copy Markdown
Contributor

@github-actions github-actions Bot commented Apr 13, 2026

This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated.

Releases

@prefresh/core@1.5.10

Patch Changes

  • f6129bbef1db5db70e292b56a6b8fff734ba2cc2 #613 Thanks @JoviDeCroock! - Align $RefreshSig$ with React's HOC-chain design to fix memo-wrapped components

    Both Babel and Oxc emit two _s(…, key) calls for a memo-wrapped component
    (_s(memo(_c = _s(inner, key)), key)). The previous status-machine approach
    mishandled the second keyed call, crashing with "Cannot set properties of
    undefined" because the outer type had not yet been registered when sign was
    called with 'needsHooks'.

    The new implementation follows the same pattern as
    createSignatureFunctionForTransform in vite-plugin-react:

    • Discriminate by typeof key === 'string' instead of a mutable status variable.
    • Always call sign with 'begin' for every keyed call, regardless of position
      in the HOC chain.
    • Track savedType (the innermost type) and defer 'needsHooks' collection to
      the first no-argument body call, guarded by a didCollectHooks flag.

    @prefresh/core's sign is also made idempotent on the 'begin' path so that
    the inner type's getCustomHooks is never overwritten by an outer HOC call that
    carries no hook information, and the 'needsHooks' path is guarded against a
    missing signature entry.

@prefresh/vite@3.0.1

Patch Changes

  • ba9db171417a3f9eb5726763eb693ca3f0cdce0d #611 Thanks @JoviDeCroock! - Add workaround for Oxc transforming differently than babel

  • f6129bbef1db5db70e292b56a6b8fff734ba2cc2 #613 Thanks @JoviDeCroock! - Align $RefreshSig$ with React's HOC-chain design to fix memo-wrapped components

    Both Babel and Oxc emit two _s(…, key) calls for a memo-wrapped component
    (_s(memo(_c = _s(inner, key)), key)). The previous status-machine approach
    mishandled the second keyed call, crashing with "Cannot set properties of
    undefined" because the outer type had not yet been registered when sign was
    called with 'needsHooks'.

    The new implementation follows the same pattern as
    createSignatureFunctionForTransform in vite-plugin-react:

    • Discriminate by typeof key === 'string' instead of a mutable status variable.
    • Always call sign with 'begin' for every keyed call, regardless of position
      in the HOC chain.
    • Track savedType (the innermost type) and defer 'needsHooks' collection to
      the first no-argument body call, guarded by a didCollectHooks flag.

    @prefresh/core's sign is also made idempotent on the 'begin' path so that
    the inner type's getCustomHooks is never overwritten by an outer HOC call that
    carries no hook information, and the 'needsHooks' path is guarded against a
    missing signature entry.

  • Updated dependencies [f6129bbef1db5db70e292b56a6b8fff734ba2cc2]:

    • @prefresh/core@1.5.10

@github-actions github-actions Bot force-pushed the changeset-release/main branch from 53f2cbe to d9dc036 Compare April 15, 2026 02:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants