4 ms·
I'm not sure how it would work since the DOM is not reactive. At the end of the day, any "view" library for the browser is a DOM builder. It cannot be reactive,
by aikah 11y ago
I'm not sure how it would work since the DOM is not reactive. At the end of the day, any "view" library for the browser is a DOM builder. It cannot be reactive, by nature.
edit: s/nature/definition
- teleclimber 11y ago> It cannot be reactive, by nature. Indeed it can't. But you can get close. The key is that the side-effect has to be much more granular. Instead of re-rendering a virtual dom for an entire component as a side-effect, the side-effect is changing a single attribute on an element, or updating its list of children. This means using a template language where one can make these associations between variables and DOM. JSX doesn't work here because its output could be anything. I am toying with an experimental framework that implements these ideas. I am convinced we can do better than diffing vdoms.
- mtzaldo 11y agommm... Instead of a dom it will be called dam (domain actor model)... look ma' I can also write cool stuffs...