Live data from Hacker News

Criticisms of Angular

leanpanda.com

41–50 of 150 posts

Re: Criticisms of Angular

#41

I haven't tried Angular yet but have built applications in React. In my opinion, frameworks like Angular suffer from a fundamental problem, that, it is almost impossible to gauge the problems of a new design unless you have a built a medium - large scale application with it which is very hard when you are just experimenting. There might be few heuristics, few rule of thumbs one can follow but still it will be hard to…

> I haven't tried Angular yet but have built applications in React. In my opinion, frameworks like Angular suffer from a fundamental problem, that, it is almost impossible to gauge the problems of a new design unless you have a built a medium - large scale application with it which is very hard when you are just experimenting.

I don't see how this is any different with React. Building a medium - large scale application in React involves just as much complexity as doing it with an Angular app, because you end up adding a Flux implementation (and all of its boilerplate code and ceremony), some sort of routing engine, a testing framework of your own choosing, a myriad of helpers, mixins, and components that a framework like Angular or Ember provide out of the box, and we haven't even started about the increased complexity in terms of tooling; babel, webpack, jsx trasnpiling. Add to that radical new concepts like css defined in your javascript files, the rapid rate at which breaking changes are introduced to React, and the moving target around data handling (Flux is out, Relay is in?) and you find yourself in a very similar situation.

You're comparing a view layer to an entire framework. It would be more apt to compare React to Angular directives but then your overarching point about complexity would be lost. I've worked on large Angular apps and large React apps and I can assure you the complexity was about the same.

Re: Criticisms of Angular

#42

He missed so much. How about non-standard invalid HTML? Breaking all searchability and accessibility? Encouraging voodoo coding?

The fact that I can declare a scope variable in a directive and it is magically available in a controller is also another one, only once one starts to dig do they find out about the less than obvious scope controls to not allow what amounts to global variables. Further down that path, variables can be declared in the template, in the controller or in a directive. There is no traceability of where state starts. Honestly I am the type that blames myself first and think I must be missing something, but there are just such junior mistakes in how Angular was implemented, that it does encourage voodoo.

Re: Criticisms of Angular

#43
Valid criticisms of Angular include that it gives you enough rope to hang yourself, that the documentation/tutorials teach you to code Angular in a bad way (abuse the $scope object, etc.) in the interest of making it "easy" and that the terminology and symbols used can be simplified.

However, once you learn to avoid Angular's pitfalls, it's a very powerful tool for creating large apps that do not collapse under their own weight.

To illustrate, how often do experienced Angular devs make $scope inheritance errors? If you are, you're not using controllerAs syntax and are coding sloppily. No framework can save you from sloppy coding.

Re: Criticisms of Angular

#45
Sometimes I feel like I'm the only one who actually likes Angular. Two way data bindings are very convenient for writing UI. I don't want to write an event listener for every onclick, onchange, and onkeypress. I want the values in my models and the values in the DOM to be in sync. I like using nearly straight up HTML as my template. I do this in Django, so why not in Angular? I like that I don't need to render things server-side because then the server is just running a REST-ful API. That way I can write different clients for the API and don't have to change the server (mobile app, desktop UI, etc.) I like the clean separation between presentation (HTML templates), UI logic (controllers), and communication (services).

I feel like Angular's biggest problem is the documentation. It starts out talking about things like dependency injection and why that's good, instead of simply displaying how to use the framework. It's got a steep learning curve and it just seems that people get scared of the documentation and run away before they really give it a try.

Re: Criticisms of Angular

#46
post #13
post #8

Earlier quoted context omitted.

why?

Because React solves only the directive part of Angular? I'm not saying it's great BTW, but comparing React to Angular is silly. That's like saying you chose lodash.js over Angular.

React usually comes with the connotation of using Flux as your data, state and control mechanism (we use ALT as our implementation) and then usually the NPM and Browserfy ecosystem to fill in the gaps as needed with libraries. It is a valid replacement for Angular but takes more of the perl or ruby approach to grab what you need and not the Angular, Java or .NET approach of most of it is already in the bag.

Personally I like the event/component oriented development style of Flux/React over procedural controllers that tend to become monolithic. The browser model was always event based, but with the flood of server side development talent the JSP / ASP controller model trickled over. It takes time for people to realize there is a better way.

Re: Criticisms of Angular

#47
post #37

So, they trot out the same tired arguments against Angular that people have been making since the beginning, and this makes the front page where people engage in serious discussion about it? Did I miss some subtle novelty about this post, or is Angular ennui just that popular on HN?

Not to mention his example is just straight wrong about $scope and ng-if. His JSFiddle examples are all using angular 1.1.5. Angular 1.2 properly binds scope inside an ng-if. I agree that angular 1.1.5 had it's warts, if that's what this is supposed to be about. The current release version of angular is 1.4, about to be 1.5. Edit: After fully reading through this blog post; it's almost all wrong. Dirty Checking: Yes,…

+1 on just saying no to server side rendering. This should be idiomatic.

Re: Criticisms of Angular

#48
Say what you will I like Angular 1. And there is a ton of resources and books all over the web to help.There is a solution to everything and it's pretty RAD

However, I'm very skeptical about Angular 2. For several reasons. First (I tested it) right now, it is way too complex and unnecessary verbose.

They wanted to support future techs like web components, observables (reactive functional programming) which are great, but it's not that easy to use.

Some people will not like the Rx approach which forces one to rethink the way one codes. There is serious mental gymnastic involved here when one has to think in terms of cold and hot streams, especially when one is used to ng1.

Of course, people who love Typescript will enjoy it,and it's true it's easier to figure out what is what with explicit types, but people who are sticking with ES5 for various reasons will hate all the boilerplate needed to get started.

And they went crazy with dependency injection,this time, this is a divisive issue among programmers and while ng1 DI was light weight, ng2 DI is going full Java which Java/C# folks will like, but i'm not so sure about the rest.

The biggest question is, how is ng2 relevant compared to React + Flux/Relay? since it tries to do the same thing but with more complexity? with that weird template syntax ([attr-read-from]="variable" , (event)="handler" ,[(read-write)]="variable", *template-directive="expression" ... )? React has JSX which is a serious advantage.

ng2 will be ready in a year at best but businesses can be tempted to just move to React in the meantime and then stick with that.

.

Re: Criticisms of Angular

#49

I haven't tried Angular yet but have built applications in React. In my opinion, frameworks like Angular suffer from a fundamental problem, that, it is almost impossible to gauge the problems of a new design unless you have a built a medium - large scale application with it which is very hard when you are just experimenting. There might be few heuristics, few rule of thumbs one can follow but still it will be hard to…

I've never understood any comparison between React and Angular. To me it seems like trying to compare a slick car to a fancy car garage. They try to solve quite different problems, right?

> They try to solve quite different problems, right?

Sort of. The problem React is solving is a subset of the problem Angular is solving. It's a bit more like comparing an older model sports car to a modern engine.

Re: Criticisms of Angular

#50
You have the calvinist way of coding: learning, coding, and working harder to improve. Believing that experience will help you build a greater skill. You put your faith in yourself and hard work. You aim for simple elegant code that talks less and does better. You believe more in efficient design than in code: you are a programmer, not a coder.

You have the catholic way of coding: believing in a framework like a church and venerating a bloated edifice with multiple weaknesses to support your most complex code.

Most of the angular coder I have met are just lazy coders believing in magic and tradition not wishing to see coding has a hard earned skilled acquired by craftsmanship.

Coding is not a "tradition", it is a "Beruf".

I am a protestant programmer, and I believe I will achieve better code with more hard work and learning than by venerating any bloated layers in between that will come in my profound gained understanding of programming.

[The one relying on his hard work] is like a man building a house, who dug down deep and laid the foundation on rock. When a flood came, the torrent struck that house but could not shake it, because it was well built. (Luke 6:48)

PS: I do angular. I fix my colleagues' works and it always make me want to puke to dig in this insanity everytime.

Post reply on HN