4 ms·
Angular.js is a JavaScript framework. It has an API that does stuff. You can look at the source code to see how it does that stuff. It helps you add events to e
by yukichan 13y ago
Angular.js is a JavaScript framework. It has an API that does stuff. You can look at the source code to see how it does that stuff. It helps you add events to elements and listen for state changes. Why would that be scary? You're going to have to learn one of these all the time if you want to do frontend development. They live shorter than fads these things, although maybe Angular.js won and will stick around.
- AdrianRossouw 13y agobecause I need to be able to rely on my intuition to guide me. when i looked at angular, I saw a lot of things that I could see would cause problems in the future. It was more about understanding myself than understanding angular really. I went through this process, not because I needed to use angular for anything, but because I needed to know that my gut instincts were right or wrong.
- yukichan 13y agoI don't understand what intuition and gut instincts have to do with JavaScript frameworks. When I evaluate libraries I do not check my emotional state or what my my stomach is telling me. I use a rational process, a heuristic: I check to see how actively developed the library is. If it's on GitHub I check how many people have starred and forked it and when the last commit was. I look at the issues list to see if it has any horrible errors that have been around forever with giant threads. I check the documentation to see if I like what it does. I scan the source code to see if it uses giant functions and globally scoped variables or does other horrible things. I also check for readability. I Google the thing and see if anyone is using it on Twitter. Then I build something small with it and if it helps more than it hurts then maybe it's good to go. The place where this heuristic has failed me is with long term big applications. I chose Google Closure for a startup once and it turned out to make everything take much more time than it should have. It was the write more do less library, but at the time there was no backbone.js and Sproutcore, Cappuccino, dojo and ext.js have all pretty much gone away. So I don't know how I feel about it now, but I definitely wouldn't use gut instinct when I can just apply rational thought.
- qntmfred 13y agoThis is why instincts are relevant. http://en.wikipedia.org/wiki/Dreyfus_model_of_skill_acquisition http://en.wikipedia.org/wiki/Dreyfus_model_of_skill_acquisit...
- aidos 13y agoI'm not the downvoter. The process you described is part of the due diligence you go through - checking for activity, longevity etc. You described a good starting point for evaluating a framework (I don't think you should have been down voted for that). Unfortunately, that's not the end of it. As with your Closure example, it's not easy to see the issues until you're up in your neck in them. At that point you have a revelation about how truly borked you are, struggling to make progress when you've gone too far to go back. That's why it makes sense to experiment a bit to see how it feels. That's not something easily quantifiable. If it were quantifiable then there would be no need for these discussions at all. There would only be one framework in any space worth looking at because it would have the best number against it. Unfortunately, in the case of application frameworks, building something small is never going to be enough.
- yukichan 13y agoIf as a manager or lead engineer someone told me they couldn't put their finger on it but a using a library just didn't "feel right" I'm not sure how I'd respond to it, but it probably would involve asking for more specific information.
- AdrianRossouw 13y agoPrecisely. That's why sometimes I need to build something with it, to be able to get that more specific information.
- onion2k 13y agoAngular.js is a JavaScript framework. It has an API that does stuff. We fear not being able to understand it, and the consequential feeling of inadequacy that goes along with that. We all avoid putting ourselves in situations that are likely to make us feel we aren't as good at things as we thought we were.
- Wintamute 13y agoAngular has managed to do things in a remarkably different way to most of the other JS frameworks out there. Opinionated app structure, enforced strict separation of concerns, views are live DOM, strictly no DOM manipulation in controllers, promises used liberally, testability right up front, etc. ... I agree its just a framework and your heuristics for framework evaluation are still valid, but it's at least understandable that your average jQuery/Backbone dev could feel some trepidation before diving in ... it may represent an enforced "level-up" in terms of their entire approach to building web apps.
- lerouxb 13y agoI agree with you except the "level up" word choice. That implies that it is necessarily better, whereas I still think that's up for debate. I think we've all been burnt by "magic" code before. A good "smell" for that sort of thing is when newbies start asking questions on stack exchange like "How do I do this in Angular?" when they should be asking "How do I do this in JavaScript?" (or rather "How do I do this at all?").
- altcognito 13y agoFor example, lets just create a controller on the fly. http://stackoverflow.com/questions/15250644/angularjs-loading-a-controller-dynamically http://stackoverflow.com/questions/15250644/angularjs-loadin... Lets do something even more basic, like use HTML5 push state: http://stackoverflow.com/questions/11095179/using-html5-pushstate-on-angular-js http://stackoverflow.com/questions/11095179/using-html5-push... Oh, that's "easy", how could I have missed that in the API docs? http://docs.angularjs.org/api/ng/provider/$locationProvider http://docs.angularjs.org/api/ng/provider/$locationProvider Oh.
- wildpeaks 13y agoRegarding how long it will stick around: Angular has a de facto advantage over similar frameworks that might be maintained on the developers' free time given Angular is maintained by Google.
- Moru 13y agoHmm, I'm not sure how I'm supposed to take this. Does or does google NOT shut down services when they feel like it? :-)
- iopq 13y agoAnd then I have an input type=email and auto complete fills in the email for the user, but Angular doesn't detect that the browser did this, and invalidates my input even though I never told it to explicitly check for it being a proper email input... it gets complicated