Angular
HTML enhanced for web applications
What is Angular
- Model → View
- Declarative ≫ Imperative
- Reusable components
- Verifiably correct code
What was happening there???
- Single data-source for entire application
- Repeated content is generated from data
But this only scratches the surface! We might want to...
- Sync data with remote server
- Client-side URL routing with history
- Trigger animations when data changes
- Sort/filter lists of data
- You name it!
ANGULAR WILL LET YOU DO IT O_O
So what's new in 1.3?
- Significant performance improvements
- New developer tools
- SVG as a first-class citizen
- More flexible Forms API
AND SO MUCH MORE
We made it faster!
- DOM manipulation
- Expression parsing and evaluation
- Text interpolation
- Filters
- Bootstrapping / $compile
Performance Results!
App startup significantly faster
[[Largetable benchmark with interpolation]]
Runtime roughly 500% faster
Performance Results!
~35% improved init time (vs v1.2.23)
5x faster on update (vs v1.2.23)
Significantly (300%) less memory.
(Select) New Features in 1.3
New form coolness
Asynchronous validators
ngModel.$asyncValidators.custom =
function(modelValue, viewValue) {
return $http.get('/profile/' + viewValue).
success(function() {
return $q.reject('name-in-use');
}).
error(ffunction() {
return true;
});
}
New form coolness
ngMessages module
Please enter an email address.
Email address is invalid.
New form coolness
ngModelOptions
- updateOn <event-name>
- debounce model updates / validation
- opt-in for getter/setter functions
- opt-in for keeping invalid model values
SVG-tastic apps
- ngInclude can now SVG
- ngRepeat can now SVG
- $compiler smarter with namespaced elements
- Angular-D3 should get a big boost from this
There's more new stuff too!
- One-time binding
- More modern Promise implementation
- Support for input[type=date]
- Long-awaited support for jQuery 2.x
New Developer Tools
- Batarang debugger re-written
- Angular-hint modules find your bugs
- Better stack-traces in angular core
- ngInspector for Safari, Firefox and Chrome