Live data from Hacker News

Complexity Creeps: Why I'm Concerned for the Future of Angular.js

daemon.co.za

51–59 of 59 posts

Re: Complexity Creeps: Why I'm Concerned for the Future of Angular.js

#51
post #42

As far as the particular issue he picks on, he is making a big deal about something that's not, at least if you accept the general premises of Angular, and trying to pin the core of his whole argument on that. Which is dumb. Anyway, I have used many, many different UI frameworks on different platforms over the years. Including different .NET systems, Backbone, Angular and to some degree web components. And many other…

Web developers are excited about Polymer and Web Components. However, using a product still on release 0.2 for building real-world, production apps is generally frowned upon by anybody over 16.

I've built a few projects with Polymer, including this public-facing one (http://securesha.re), which is a poster child for why you shouldn't use pre-alpha software (see the blown stack in the console; this was working just fine a few browser releases ago). Thankfully, it's not a critical app and it's more of a proof-of-concept than anything else. The source is available below [1].

It was a joy to build Secureshare with Polymer and it really made me rethink what an HTML element can be and what it can do. You have to unlearn years or decades of assuming that an HTML element has almost no useful API; with Polymer, you're likely to define many core application functions directly on DOM elements themselves. It's a lot of fun once you get used to it. and really opened my eyes to what was possible with this new paradigm, and it is unquestionably cleaner than what has come before.

More than anything, I'm excited for the inevitable deluge of web components; finally, UI libraries that can that be mixed and matched in any web application without regard for what other JS and CSS is on the page. True isolation allows us to create truly fantastic projects.

[1] https://github.com/STRML/securesha.re-client

Re: Complexity Creeps: Why I'm Concerned for the Future of Angular.js

#52
post #42

As far as the particular issue he picks on, he is making a big deal about something that's not, at least if you accept the general premises of Angular, and trying to pin the core of his whole argument on that. Which is dumb. Anyway, I have used many, many different UI frameworks on different platforms over the years. Including different .NET systems, Backbone, Angular and to some degree web components. And many other…

Did you read my preface or the other 2 articles in the series?

My argument was just 'this is wrong. dont do that', not that angular was bad because it did that.

I am excited about web components and I'm dying to find the right project to build something with polymer, but they just aren't mature enough for this yet.

Re: Complexity Creeps: Why I'm Concerned for the Future of Angular.js

#53
post #43

The author is concerned about the future of Angular because of the idiosyncrasies of one method of including dependencies. I mean, really? Is it so bad, the stench of automatic dependency injection, it overcomes all other beneficial features of Angular, it would jeopardise it's future as a web framework, such that it would lose compatibility with future browsers and your web app built in angular will stop working, wi…

no. i was worried about the fact that people weren't questioning the logic of it, and that once this kind of magic takes hold ... it's really hard to take it out again.

Nobody said anything about future browsers and losing compatibility.

I do think that if this kind of thing grows, the system will become complex enough that developers will move to different frameworks that do similar things but don't have all this magic and baggage.

Re: Complexity Creeps: Why I'm Concerned for the Future of Angular.js

#54
post #50

AngularJS is not complex , when I think complex , I think SpringMVC or Struts complexity. AngularJS has problems ,but complexity is not one of them, definetly. Seems like JS programmers who only know JS think they can get away with ignoring patterns like dependency injection, Guess what, in order for code to be maintainable and testable it needs it. Front-end is about GUI dev,and that's where OOP shines. It's high ti…

Nope. agreed.

I just felt that this little thing was complex, and that something like this can spread over time.

I had no issue with dependency injection either, just the magic format.

Re: Complexity Creeps: Why I'm Concerned for the Future of Angular.js

#55
post #32

Earlier quoted context omitted.

dependency injection is fine. just the magic argument detection wasn't a good idea. Backbone views has nothing to do with this, imo. The thing I miss the most when using backbone, and I use it a _LOT_, is observables. Binding and unbinding model events can get really tedious. Marionette really does help for that, but this stuff can still get out of hand.

It does when it comes to not leaving your views in an ugly string representation of html - you use a build process of some sorts to get around that fundamental flaw so that you can still use a nice html template file. That alone was enough to sour me on Backbone, hence the comparison. This flaw in Angular isn't nearly as deep was my point.

HTML is HTML, why does it matter what file type it resides in? All my templates are stored according to the view's type within my ./templates folder. If I want to include the HTML in an "actual" HTML file I can do that too. Have you even used Backbone?

Re: Complexity Creeps: Why I'm Concerned for the Future of Angular.js

#56
post #31

Earlier quoted context omitted.

maybe, except that I try to improve how I do things on every iteration. i've been finding that it helps me to think about these things in a more concrete manner, so that i can vocalize to myself what I didn't enjoy in the recent experiences.

I found Rich Hickey's dissection of simplicity to be dynamite as usual: http://www.infoq.com/presentations/Simple-Made-Easy

this was a great watch. thanks for that.

It helped me focus a lot of things I have been feeling innately for a while.

Re: Complexity Creeps: Why I'm Concerned for the Future of Angular.js

#57
post #48

Earlier quoted context omitted.

I disagree with you that the hacky DI scheme is something that should be ignored. It's brittle and really has no place in the core of a library like this. It's not an end of the world thing, but it's definitely worth addressing. I totally agree with you that Angular is overly complex. I feel like they somehow either overshot or undershot the correct layer of abstraction, and I'm not sure how. It can produce really el…

Hm. Forget I mentioned the term "global variable" since it is a religious term. I am not trying to argue against proper encapsulation and coupling/decoupling. Those things are great. Classes and modules and great. Not sure how you see me as attacking those things. Say I am working on a web application and I want to use AJAX. I should not have to keep saying in every place that I want to use it "oh by the way I am usi…

I think you should basically say "oh by the way I am using AJAX", whether that means using Angular-style DI or require or a mixin some other means. In a language with a built-in concept of modules, you'd have to import or include something like that, wouldn't you?

There are some practical benefits, aside from the general happiness provided by namespacing. Not that every single app needs this, but it's pretty handy for example to be able to substitute a mock AJAX service for testing and offline development purposes.

Re: Complexity Creeps: Why I'm Concerned for the Future of Angular.js

#58
post #11

While I do the think author makes too big a deal about this, I very much agree with them . The main issue is whether or not we should be teaching people, as a first brush with Angular, to code things with "automatic Dependency Injection", where the types are inferred from variable names. The alternative, and only way to code a "real" application, is to pass the names of things you want injected as strings. For people…

I'm only making a 'big' deal about this because I have given this serious thought. This is the third part in a series of articles where I was trying to understand why my intuition was telling me that there was something not quite right about angular. I finally managed to track it down to this specific little thing, and how the unintended consequences of a feature like this could have far ranging consequences to it as…

Why would you expect Angular or any current platform to be relevant in 5 years?

Re: Complexity Creeps: Why I'm Concerned for the Future of Angular.js

#59
post #58

Earlier quoted context omitted.

I'm only making a 'big' deal about this because I have given this serious thought. This is the third part in a series of articles where I was trying to understand why my intuition was telling me that there was something not quite right about angular. I finally managed to track it down to this specific little thing, and how the unintended consequences of a feature like this could have far ranging consequences to it as…

Why would you expect Angular or any current platform to be relevant in 5 years?

Most platforms, at least major ones, ARE relevant for many years. Of course we have yet to see if Angular will be one of them, but it's looking like it will.
Post reply on HN