re: SvelteJS: The next big UI framework VIEW POST


I don't necessarily agree with the "virtual dom is a bottleneck" argument, Attachment is an expensive process for the browser and the whole purpose of the virtual DOM is to prevent unnecessary re-paints. I am also curious of how well does Svelte works with immutability as it seems to rely on change-detection as opposed to unidirectional data-flow. Lastly, the word framework has been thrown around but neither Vue or React are frameworks but libraries, and I think Svelte fits that description as well as there are no set ways of doing the data-layer like Angular.


Thanks for reading and thank you for the comments.

I didn't expand on why I think the virtual DOM is a bottleneck. The short answer is that it performs a lot of unnecessary DOM diffing in the process of deciding what to update, since when using the virtual DOM the framework/library don't have any trace of the data flow. A lot of code also runs more times than necessary. If you don't trust, check out the talk by one of the founders of SvelteJS (youtu.be/AdNJ3fydeao).

I think you could use immutability, but I haven't tried it. But looks like you could do something like this(svelte.dev/tutorial/svelte-options)

Svelte has a store feature for handling data if that's what you are referring to.


Thanks for the reply, I'll watch the talk!

code of conduct - report abuse