Live data from Hacker News

Solidjs – JavaScript UI Library

solidjs.com

91–92 of 92 posts

Re: Solidjs – JavaScript UI Library

#91
post #79

Earlier quoted context omitted.

By fine grained update control -- do you mean similar to mobx + react. I think "automatic change tracking" is the phrase I've seen thrown around. If so this was always the most appealing method for performant UI's for me. You have some conceptual overhead of dealing with observables, but in return you get to ignore the majority of performance -- components only update when the data they need to use changes, and you n…

Reading this I'm reminded of knockoutjs, which the author of SolidJS cites as an influence. I remember at one point, years ago, trying to figure out why it was so much faster than AngularJS. Two things seemed to be going on: 1) It was only updating the parts of the DOM it needed to 2) To do this it seemed to 'automagically' be inferring dependencies. I wondered how they did this second thing and guessed that it was p…

It just tracks function calls. The general idea is that if a function is called in the render cycle of a component, that registers as a subscription for that piece of data that function returns. There is some magic with proxy and getter to hide the functions but basically that's it.

Re: Solidjs – JavaScript UI Library

#92

I read this article[0] which was written by the framework’s author. It looks like it gets closer to “reagent in plain Javascript,” which is pretty great. JS development would benefit greatly from a native “immutable, nestable, performant, deep-compare-by-value” data type that supported something like these operations: atom.get(path) atom.set(newValue) // returns new atom atom.set(path, newValue) // returns new atom B…

Isn't immer pretty close?
Post reply on HN