DEV Community

Discussion on: Vue.js vs. React — Not Your Usual Comparison

Collapse
leob profile image
leob • Edited on

Interesting, some remarks - I think what makes Vue simpler than React (i.e. smaller learning curve) is that it's much more opinionated ("one way to do it") and way more "batteries included" - routing system is built in, state management is there (Vuex), and so on.

Fundamentally, Vue just "does" a lot more for you - for instance, reactivity is built in and taken care of, without you needing to worry a lot about re-renders (big topic in the React world).

I don't see nearly the same amount of discussions in the Vue world about best practices like render props, HOCs, hooks, Redux Thunk, Redux Saga, and so on and so forth, all of which can be very intimidating and very confusing for a newbie. The Vue world has less of this probably because it's way more "opinionated", and more 'batteries included'.

One caveat - the next release of Vue is apparently going to switch to React-style hooks and stateless "function components", so that's probably going to cause quite a bit of confusion initially - I don't know how that will work out for Vue's learning curve and intuitiveness.

Collapse
domagojvidovic profile image
Domagoj Vidovic Author

"render props, HOCs, hooks, Redux Thunk, Redux Saga" - exactly this!

TBH, even though I used render pros and HOCs for such a long time, I still don't understand them completely.

I know how they work. I create them and use them. But still, there are things about them so counterintuitive that can't grasp them completely.

Collapse
leob profile image
leob • Edited on

The problem is, at some point you "get it" and you understand how it works, but you only retain that knowledge if you keep using it ... if you don't use it for some time, then it fades away (I compare it to learning calculus and differential equations during math lessons, it's not hugely difficult per se and it's possible to learn it but don't ask me to do it 4 or 5 months later, sad to say it's all gone).

It's arcane knowledge and it doesn't come naturally. And note that most of this has gone away after hooks were added to React, so none of this HOC and props stuff and whatever was really that fundamental after all, it's just a bag of tricks (with trade-offs) to technically accomplish something.

This is what I've always seen as the biggest drawback of React, none of this stuff lets me focus on solving "business problems", while Vue lets me do just that.

Thread Thread
domagojvidovic profile image
Domagoj Vidovic Author

Exactly! With Vue, I focus just on the business problem.

With React, I first need to think about possible solutions and pick something from 3 different options.

In Vue, there’s usually just one option - and it’s the simplest one for sure.

Collapse
khorne07 profile image
Khorne07

Agree with that, React is more complex and less newbie friendly, but once you got into it (at least gor people like me who enjoy challenges) is pretty fascinating world and don't find a need to look outside, instead I try to get better on it and understand everything. I know not everybody thinks the same way and maybe some people is just overwhelmed by the complexity of React and fell a great relieve when they find a much simpler tool that in the end allows to do nearly the same. But is not my way so 🙂...