AngularJS
The bridge between today and
tomorrow's web
Slide 2
Slide 2 text
• @toddmotto
• GDE
• Lead engineer @ Mozio
• Google, Intel, Rolling Stone
• Open source (ngStyleguide, conditionizr)
Slide 3
Slide 3 text
No content
Slide 4
Slide 4 text
The story
• Yesterday, where we came from
• Tomorrow, where we’re headed
• Today, what’s available
• Angular future thinking/mappings
• Angular today
• Angular tomorrow
• local and session storage
• History API
• Indexed DB
• Web SQL (kinda)
• Native form validation (required, email etc)
• FormData
• Dataset (custom data-*)
Slide 17
Slide 17 text
• HTML5 semantics
• File/FileReader API
• classList API
• Drag and drop
• postMessage
• contenteditable
Slide 18
Slide 18 text
And breathe. HTML5 is huge.
Slide 19
Slide 19 text
To make things even more difficult for us...
Slide 20
Slide 20 text
Frameworks and Model-View-Whatever
Slide 21
Slide 21 text
• Angular
• Knockout
• Ember
• React
• Backbone
Slide 22
Slide 22 text
Why frameworks?
Slide 23
Slide 23 text
We're still missing stuff!
• Templates/Encapsulation/Components
• Two-way data binding/Model data
• Promises and Class-like components
• Modules
• Dependency Injection (DI)
• Software patterns (MVC/MVVM)
Web Components: Shadow DOM
▾
▾#shadow-root (user-agent)
Slide 32
Slide 32 text
Web Components
HTML Imports
Slide 33
Slide 33 text
Web Components: HTML Imports
Slide 34
Slide 34 text
ES7
Object.observe - deprecated
Slide 35
Slide 35 text
ES7: Object.observe - deprecated
// html5rocks.com/en/tutorials/es7/observe
// Let's say we have a model with data
var model = {};
// Which we then observe
Object.observe(model, function(changes){
// This asynchronous callback runs
changes.forEach(function(change) {
// Letting us know what changed
console.log(change.type, change.name, change.oldValue);
});
});
Angular 2: Preparing
• Use controllerAs and bindToController
• Use new component() method
• Integrate ES6 and/or TypeScript
• ngForward and ngUpgrade
Slide 72
Slide 72 text
Takeaways
• Angular helps deliver the future now
• Frameworks will always be ahead of the web
• Libs/frameworks help sculpt the future
• Angular 2, ES6 + TypeScript is coming
• Prepare for it now!