DEV Community

Cover image for My Completely Biased Reasons for Choosing Angular

My Completely Biased Reasons for Choosing Angular

John Woodruff on June 11, 2021

I wanted the title to be painfully obvious. Just in case that didn't make it obvious enough, let me be even more clear. This is my completely biase...
Collapse
 
oniichan profile image
yoquiale

I like Angular because it's opinionated and because of the directives, the same with Vue. I dislike React because it doesn't has directives and you have too much freedom, and it uses css in js, which makes no sense to me.

Collapse
 
dgreene1 profile image
Dan Greene

You don’t have to use CSS-in-JS with React. In fact, most people use standard CSS Modules (just like I think Angular uses).

Collapse
 
valeriavg profile image
Valeria

I respect opinions that are diametrically opposed to mine. In fact I believe that diversity is a very good thing and not only in tech. With that said, it hurts me to see how the option to not use any framework at all simply became not an option. A framework, architecture or any sort of abstraction layer can and should be chosen or (blasphemy!) created for a particular project. After all, every programming language has it's own ways of doing things, limiting opinions and providing easy solutions for common problems.
But the higher the level of abstraction the less understanding you have of what actually is going on. This makes things harder to debug, fix and optimise.
Having said that, I agree that choosing a framework based on what you know best is wise. But by knowing I mean a deep understanding of how it works, what it can and cannot do and why. Which is always easier with your own code or a third-party code with the smallest possible scope.

Collapse
 
johnbwoodruff profile image
John Woodruff

Thanks for the comment! I actually completely agree that no framework is just as valid of a choice, and one that I’ve utilized on occasion. Honestly not including it was simple oversight, since the post was specifically about why I chose this framework for side projects, and a natural comparison is other comparable frameworks. But thanks for bringing up that no framework is a totally valid option as well! I 100% agree with you! 😊

Collapse
 
steveblue profile image
Stephen Belovarich • Edited

Been working a lot with React, Vanilla JS and Web Components lately and I honestly miss Angular for all the reasons stated above.

It’s not trivial to maintain build infrastructure for modern JavaScript applications, but Angular CLI makes it so easy!

I’ve often wondered how many of the ideas in Angular were inspired by GWT, i.e. class Decorators and Dependency Injection. It would make sense for the Angular team to provide a similar interface to GWT if they wanted engineers at Google to adopt Angular over GWT and then lean so hard into these concepts while the rest of the JavaScript community was going the way of functional. Functional is OK, but unlike classes I find functional architectures like React Hooks to be a barrier to entry in JavaScript for people coming from other languages. Angular has stood the coarse, while React has changed dramatically over the years, causing a lot of friction within that community.

You’ve made your bed, now lie in it.

Collapse
 
johnbwoodruff profile image
John Woodruff

It’s crazy to me how much mental overhead goes away when using Angular especially with Angular CLI. Things I had to worry about with any other technology that are simply taken care of by the CLI. It’s pretty great.

Thanks so much for commenting!

Collapse
 
iainfreestone profile image
Iain Freestone • Edited

" I, John Woodruff, choose to use Angular in personal projects small and large."

That is all that needs to be said. Choose what you are happy with. Its not a competition. Best of luck

Collapse
 
andreidascalu profile image
Andrei Dascalu

This is a place of discussion and reasond and point of view are important.

Collapse
 
johnbwoodruff profile image
John Woodruff

Agreed! That being said I also love hearing what people love about their choices. (From a non-confrontational perspective haha)

Collapse
 
hungluong profile image
Hung Luong

I still remember the first days I dipped into the deep waters known as frontend development. It was literally the same as that joke article "How it feels to learn JavaScript" or something I read back then. Angular was a godsend as I instantly understand everything that need to be done to put stuff on screen and be done with it.

Collapse
 
brunnerlivio profile image
Livio Brunner

100% agree with your point on "opinionation". The beauty of Angular is that because of its similar paradigms you'll find it so much easier to on-board to any other Angular project.

In contrary, for complex React application it's like the wild-west; so many different approaches and libraries which may or may not be used, depending on the opinions of the team who maintains the app.

On the flip-side -- and that is just fundamental differences of Angular vs React specifically -- it always bugged me how much overhead I need to create for a single component. With React it's as simple as creating a function in a simple TSX or JSX file. I usually see that in Angular apps I create way less (stateless-) components because of that.

I also prefer React JSX over Angular template engine. It just feels so much more "native" to use a "syntax sugar"-ed JavaScript than a completely custom HTML engine.

I think StencilJS nicely solves both of these mentioned issues by offering Class & Functional components as well as JSX templates.

Collapse
 
johnbwoodruff profile image
John Woodruff

Thanks for the thoughtful reply! I absolutely love Stencil, I’ve actually written a fair amount about it here in dev.to! 😂 I will say though that I don’t personally use Stencil for anything other than component libraries/design systems, and it comes down to the fact that I’m way more productive with Angular when building large apps. (Again, entirely opinion based)

Collapse
 
mayvid14 profile image
Mayvid14

Angular was the framework I started my career with, and maybe because of that I love it. It has (almost) everything you need to build an application. From SSR, to PWA, to drag and drop support. I have found myself struggling with other frameworks due to this fact.

As time passes by, I may not be using Angular on a day to day basis, but it remains my first choice when it comes to personal projects 😅

Collapse
 
johnbwoodruff profile image
John Woodruff

Exactly, while I use a variety of other frameworks and technologies, my personal projects are basically always Angular! I love it too much to choose anything else.

Collapse
 
dgreene1 profile image
Dan Greene

You can easily mock/spy your dependencies without dependency injection since Jest has module spies. That way you don’t have to worry about a bunch of boiler plate just to be able to mock a dependency.

jestjs.io/docs/jest-object#jestspy...

There’s too much cruft with dependency injection (in my opinion). And it makes debugging challenging.

Collapse
 
walkingriver profile image
Michael D. Callaghan

Well said, John!

Collapse
 
johnbwoodruff profile image
John Woodruff

Thanks!

Collapse
 
tojacob profile image
Jacob Samuel G.

Yep

Collapse
 
hasnaindev profile image
Muhammad Hasnain

I agree with your conclusion. Choose the tool best fit for the problem you're trying to solve.

Collapse
 
johnbwoodruff profile image
John Woodruff

Thanks for the comment Muhammad! Yep, I’m very much a proponent of this mentality!

Collapse
 
johnbwoodruff profile image
John Woodruff

Thanks Stephen! I appreciate the comment!