Skip to content

Releases: preactjs/signals

@preact/signals@2.0.0

17 Dec 07:47
9022d4a
Compare
Choose a tag to compare

Major Changes

  • #604 fea3e8d Thanks @JoviDeCroock! - Defer all DOM updates by an animation frame, this should make it so
    that any previously synchronous DOM update will be instead delayed by an
    animation frame. This allows Preact to first perform its own render
    cycle and then our direct DOM updates to occur. These will now
    be performed in a batched way which is more performant as the browser
    is prepared to handle these during the animation frame.

    This does impact how Preact based signals are tested, when
    you perform a signal update, you'll need to wrap it in act. In a way
    this was always the case, as a signal update that resulted in
    a Preact state update would require it to be wrapped in act, but
    now this is the norm.

Minor Changes

Patch Changes

  • #609 8e6e2de Thanks @JoviDeCroock! - Change timing to a double microtask so we are behind the Preact render queue but can't delay as much as a user-input coming in.

@preact/signals-react@2.3.0

17 Dec 07:47
9022d4a
Compare
Choose a tag to compare

Minor Changes

Patch Changes

  • #611 57a7d38 Thanks @Xstoudi! - Silences noisy warnings about useLayoutEffect whilst using SSR by switching to an isomorphic layout effect hook

  • #624 18b2f29 Thanks @JoviDeCroock! - Fix the stubbed ReactElementType to use the newly added traditional element in v19

@preact/signals-react-transform@0.5.0

17 Dec 07:47
9022d4a
Compare
Choose a tag to compare

Minor Changes

Patch Changes

  • #628 c3e8e8c Thanks @Artur-! - Avoid cloning the top-level component function when we are
    prepending useSignals. This fixes compatability with fast-refresh
    as it requires the function identity to correctly leverage its
    cache.
  • Updated dependencies [18b2f29, 57a7d38, 18b2f29]:
    • @preact/signals-react@2.3.0

@preact/signals@1.3.1

27 Nov 19:43
d4ff246
Compare
Choose a tag to compare

Patch Changes

@preact/signals-react@2.2.0

08 Aug 07:53
e046714
Compare
Choose a tag to compare

Minor Changes

@preact/signals-core@1.8.0

04 Aug 06:21
8fab8fe
Compare
Choose a tag to compare

Minor Changes

  • #587 cd9efbb Thanks @JoviDeCroock! - Adjust the ReadOnlySignal type to not inherit from Signal
    this way the type can't be widened without noticing, i.e. when
    we'd have

    const sig: Signal = useComputed(() => x);

    We would have widened the type to be mutable again, which for
    a computed is not allowed. We want to provide the tools to our
    users to avoid these footguns hence we are correcting this type
    in a minor version.

@preact/signals-react-transform@0.4.0

23 Jul 07:31
7494fb2
Compare
Choose a tag to compare

Minor Changes

@preact/signals@1.3.0

06 Jul 09:23
26d49bf
Compare
Choose a tag to compare

Minor Changes

  • #578 931404e Thanks @JoviDeCroock! - Allow for passing no argument to the signal and the type to be automatically inferred as T | undefined

Patch Changes

  • Updated dependencies [931404e]:
    • @preact/signals-core@1.7.0

@preact/signals-react@2.1.0

06 Jul 09:23
26d49bf
Compare
Choose a tag to compare

Minor Changes

  • #578 931404e Thanks @JoviDeCroock! - Allow for passing no argument to the signal and the type to be automatically inferred as T | undefined

Patch Changes

@preact/signals-react-transform@0.3.2

06 Jul 09:23
26d49bf
Compare
Choose a tag to compare

Patch Changes