What were your thoughts?
It seems to offer some cool things, but I worry about the intermingling of the dom with your logic (ie things like ng-controller etc), but maybe this is just the naive usecase presented in the examples.
What were your thoughts? It seems to offer some cool things, but I worry about the intermingling of the dom with your logic (ie things like ng-controller etc), but maybe this is just the naive usecase presented in the examples.
It seems more mustache actually with the restrictions to what logic can go in the HTML.
But what I was talking about is how they mix the logic in with the HTML, specifically things like "<tr ng-repeat="project in projects | filter:search | orderBy:'name'">"
I would imagine this would make reading HTML even more difficult, rather than easier.
I'm a designer [but thankfully with a CS background from what feels like a lifetime ago] and I've been playing around with Angular in my spare time by making a simple app (well simpleish it starting to get more ambitious :)
The last couple of weeks have been a steep learning curve with a lot of help from my developer genius @treasonx.
I'd done some work with Rails before which had felt pretty easy with their very opinionated view of how MVC should be (convention over configuration etc). Angular boldy claims that it's very flexible how you can use it, but so far in my brief experience unless you're doing a really trivial example you have to follow their philosophy.
...one of the biggest surprises is like @iano mentions how logic is transferred to the view. In addition to that, you're encouraged to move a lot of app logic into 'Services' (blocks of code to manage your model, storage, communication etc) and 'Directives' (blocks that allow you to wrap up snippet of view/app logic as a reusable module). This leaves your controllers surprisingly empty.
The hardest part for me has been sparse and confusing documentation. Stackoverflow and countless jsfiddles have been a lot more useful to me than the official Angular site in terms of learning.
If no one beats me to it I'm planning to write an "Angular for Interested Designers" type tutorial to help non-coders interested in getting started with Angular...
I think AngularJS is probably the most forward thinking JS framework out there :)
I recently built a configuration driven component framework for my startup, swoop.com. What we needed was a way to easily compose a "landing page" with as little changes in code as possible. It had to be entirely configuration driven. Also we needed the ability to quickly "hack" a feature in a few hours if not minutes :)
Why did I choose Angular out of all the choices out there?
1) It does all the DOM heavy lifting for you! (bindings and directives)
2) clear way to test all of your application logic
3) There is an "Angular" way of doing things.
4) The ability to declaratively build a complete UI.
5) Dependency injection!!!
To my first point DOM heavy lifting..
Most client side frameworks do a lot to help you structure your all and provide nice tools for managing data and subscribing to events in your app. To me these are the easy problems to solve! What I really wanted out of my framework was to not worry about DOM manipulation at all. DOM manipulation is tedious and I dont want to have to do it! Or do as little as possible. KnockoutJS does a good job but its not an entire framework on its own and the bindings can be fragile. Angular keeps my UI in sync with my data model and i dont have to worry about it.. I spend my time focusing on my domain logic and less on DOM manipulation!
3 An angular way of doing things.
Rails is awesome because it pushes developers into doing things the rails way. This gives you some great flexibility to grow a team in the future. Any rails developer should be able to easily jump in and help out with your app.. If angular gains popularity the same should happen here. Do things the angular way and people will quickly understand the patterns.
And finally point 4 declaratively building UI
Not everyone is a JS ninja, nor should they have to be. The great thing about CSS and HTML is its declarative. Its much easier for someone to understand and the skill level required to build declarative UI is much lower. So for building a team you only need 1 or 2 excellent JS devs who do the heavy lifting of building reusable directives. Then designers and junior developers can reuse the directives with little or no assistance. They dont even have to touch JS code, it can all be done through declarative HTML :)
The "DOM heavy lifting" (as James calls it) is for me the most magical part of Angular. In my sample app that I'm building I have a bunch of things like message counts, date of most recent message, extract of the most recent message etc....
With the magical view-model binding in Angular I never have to figure out code to update all that stuff - it just happens MAGICALLY. It makes stuff so fast it almost feels like cheating :)
From a design perspective it's also really changing my view of what's possible in terms of interactions. In the past I've put a mental handbrake on a bunch of ideas because I know they would be too intensive to develop. Angular opens up options for much more real-time experiences.
Thanks for your feedback! Team Branch
Please refresh the page and try again.