Preact Signals just got a huge performance boost: Signals rendered as text/props & effects only "pull" as fast as needed for rendering. Since computeds run as-needed, they now only re-run as often as their downstream DOM output can be painted. H/t to @jovidecroock.com for making this happen.
Post
@trueadm.dev Can Svelte ship this? Or does Svelte need this?
Looking at back why we reverted it, it was because of things like the `disabled` attribute. If you don't apply that in a microtask, then the next event coming in will read the stale value and do the incorrect thing. Flushing template effects on events just gets us back to where we started.
0 reposts5 likes
H/T @jakearchibald.com for pointing that out to me, that prevented this from shipping with that bug, hero!
It is, it has been shot with the latest version. Just that effects and dom-updates have slightly different queueing mechanisms github.com/preactjs/sig...
github.comgithub.com