Remix.run Logo
wg0 4 days ago

You can now use React Compiler and there would be no virtual DOM.

Already being used in production at large code bases.

jazzypants 3 days ago | parent | next [-]

The React Compiler does not remove the virtual DOM. You literally cannot use React without a virtual DOM.

bogdan 4 days ago | parent | prev | next [-]

You can and you can't. There's still plenty of very popular libraries that don't behave correctly with it. That's more on the libraries than on the compiler but that's the current state of things.

ksh09 3 days ago | parent | prev | next [-]

I genuinely don't know what lead to the compilers when we already had a simpler concept of signals.

puskuruk 4 days ago | parent | prev | next [-]

React Compiler(originally react-forget) is a build-time tool that automatically optimizes your React app by automatically memoizing your code. It only replaces the manual ceremony of useMemo, useCallback, and React.memo with automatic caching at compile time. So, it's fixing the problem they introduced by React itself or you we can call it a "trade-off" in a sense

dashersw 4 days ago | parent | prev [-]

Yeah afaik React Compiler doesn't really replace virtual DOM.