Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

This relieves the developer of keeping track of DOM state, as you only declare the render function once

A good part.

and after that you only need to manage state

A part where to change a[n].b.c:

React: you either split into unhealthy number of “components”, which are never reused and require tons of pass-through, or only manage state as a sequence of unnatural to js “reduce” operations.

Vue: give away your data to Vue, because once it hits `.data` it gets charged with properties incompatible with the entirety of js language.

Vue is essentially a separate programming language, which somehow managed to sell the manual transpilation to its users. React did the same being Haskell-like variant. The “upon native functionality” of this is equivalent to python3.dll being upon a native functionality of C++.

Most of your points still valid, I only wanted to unfold that “only manage state” bit. It’s sad that libraries like Mithril aren’t the default, and instead monstrosities like React are.



You have to manage state within the rules of the framework, that's true. But the hard part of programming usually isn't syntax. Who cares if it's a different language/paradigm? It's a simple language and I only have to say a few words. It's still orders of magnitude less complex (this is not an exaggeration) than rolling your own framework with vanilla JS.

I would encourage you to find out why React is popular and why Mithril isn't on the assumption that the world isn't crazy.


Are you familiar with both? Finding out why React is popular is a hard task because every article starts with comparing it to jQuery and usually ends there. I’d like to learn from the relevant side, not from the one centered around some obvious strawman. A link or just few words, I would really appreciate it.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: