News for hackers. Stuff that matters.
Re:Reactivity Without Virtual DOM by HereBeBeasties on Saturday February 11, 2023 @08:52AM (#34752287)
As ever, it depends on your use case. If you're rendering 20 TODO items then who cares?

If you're rendering thousands of items on an SVG data visualisation, sure it matters.

You can tell it matters because otherwise React wouldn't have implemented escape valves to improve performance, like shouldComponentUpdate.

You can get around this by using persistent data structures with lenses, which is how Elm works. Then it's just reference equality checks as you go down the tree, which is inherently faster.

Re:Reactivity Without Virtual DOM by password11 on Monday February 13, 2023 @09:54PM (#34784643)
> If you're rendering thousands of items on an SVG data visualisation, sure [virtual dom] matters.

I am not educated on the no-virtual-DOM-hype.

What actually costs more here:

(1) the diff and vdom algorithm or

(2) the actual DOM calls?

I always thought it was (2)... is this right?