News for hackers. Stuff that matters.
Re:VanJS (Vanilla JavaScript): smallest reactive UI framework by nathell on Thursday May 25, 2023 @04:11AM (#36068208)
This. I originally thought this was a rebranding of http://vanilla-js.com/ and I'm disappointed.
Re:VanJS (Vanilla JavaScript): smallest reactive UI framework by vmfunction on Thursday May 25, 2023 @04:15AM (#36068230)
what is interesting about that is when I saw solid.js performance chart, it is the closest to vanilla js in terms of performance.
Re:VanJS (Vanilla JavaScript): smallest reactive UI framework by MrJohz on Thursday May 25, 2023 @06:27PM (#36077187)
SolidJS is probably the closest thing to a vanillaJS framework that you can get, in that 90% of the time it's doing the same DOM manipulations you would be doing, but with a nicer interface. So if an update causes a class to change, there's no tree to diff - that class attribute gets changed directly.

The non-Vanilla stuff is the signals implementation, which is kind of an RxJS-esque observable system, but more lightweight, and more push-based. It's very similar to Svelte, but with a React/hooks-like API (although far fewer rules to remember!) As I understand it, this system is pretty efficient, which means for simple use-cases, it's not adding much overhead over basic vanilla stuff.

The disadvantages (because there are always some) mainly come from the small ecosystem - there's not many off-the-shelf design toolkits, the documentation is a bit scratchy, etc. That community is still growing though, so that stuff will get there.