Nowadays having a good command over a UI framework (or library) like - React, Angular, or Vue - is a must to handle front-end tasks efficiently.
Also, these UI frameworks or libraries offer you a lot in terms of introducing you to a variety of different concepts like - data fetching from an API, routing, state management, etc. And there is no denying that grasping these concepts makes your life, as a developer, easier.
- “What do I learn next?”
- “Is React something I should be starting with? Or, should I rather put my efforts in Angular?”
- “Are my efforts gonna pay me off in my career if I choose one thing over the other?”
A lot of questions. A lot of doubts.
When you’re a beginner, and want to to taste UI development as a whole, you surely are gonna face this dilemma of choosing one thing over the other.
And that’s okay. Your confusion makes sense.
This blogpost is React specific, therefore, it doesn’t talk about Vue and Angular and why one should choose them. I should be honest with you. There is a personal liking towards React and that is why I chose to write this post to shed light on why one should jump right into the world of React, as of 2021.
Here are 3 good reasons for that:
And that further means, you’re free from the burden to learn additional, framework-specific things and can focus entirely on learning core concepts such as creating and configuring components, sharing data between components, writing efficient, non-repetitive code, and managing the state of your application.
That’s a good thing, right?
React is beginner-friendly
React is a small library. It has a lesser amount of concepts to grasp.
To a good JS developer, it should take roughly 10-15 days of dedication to master the core concepts of React. That’s an estimate, so it is bound to vary from person to person. But the point is it takes less time to learn React.
I agree that it is not a good reason to choose React over other UI frameworks.
But along with being lean in size, React is also beginner-friendly so that many people find it easy enough to grasp.
And the topmost reason is its declarative nature, which means a developer just needs to tell React API ‘what’ actions to perform, and API will take care of carrying out the action without him having to bother on ‘how’.
Its fusion with JSX makes it even easier syntactically since JSX looks like HTML, and beginner developers have an easy time understanding what exactly is going on.
React ecosystem offers a lot of flexibility
We discussed that React is a small library. And, it is not a go-to strategy for all sorts of front-end problems. That’s why you’d need to add a lot of third-party libraries to solve problems that React can not solve on its own.
React offers its local state management system and architecture for creating components. On top of that, if you would want to have an API for data fetching you could use Axios as a third-party API or any other standard library for that matter.
Or if you’d like to have routing handled you can use another third-party library.
You are free to choose.
Having such flexibility means you are allowed to bring the best tools together to build an application, which is a rare case in frameworks that are so rigid to allow things only in a particular way.
Of course, there are a lot of other powerful reasons like - React’s performance, it’s virtual DOM API, its re-rendering capabilities or other stuff. But beginners do not really care about those strengths in the beginning itself.
So, why bullshit unnecessarily?
I hope you got some of your confusions cleared up.
Additionally, at the end of the day, it really does not matter whether you choose to React or not because frameworks and libraries are tools and not the solution. So in your whole development career you are gonna change a lot of tools, but what matters is the problem being solved.
So do not be so emotional about choosing a wrong thing and regretting later, because you know what?
You always have an option to opt-out. Always.