About me
• @Quramy (Yosuke Kurami)
• Frontend Web Developer at WACUL INC.
• develop SPA with Angular(1 and 2)
• Maintaining a Vim plugin for TypeScript
• http://vimawesome.com/plugin/tsuquyomi
• I don’t use nor know Wordpress.
Remember:
AngularJS is not fast
https://www.codementor.io/reactjs/tutorial/reactjs-vs-angular-js-performance-comparison-knockout
Slide 7
Slide 7 text
“Compilation” in Angular
• Angular has “template compiler”:
• creates functions optimized for
manipulating DOM, to defeat VDOM.
Slide 8
Slide 8 text
Compilation is too heavy
Slide 9
Slide 9 text
No content
Slide 10
Slide 10 text
No content
Slide 11
Slide 11 text
JiT v.s. AoT
• JiT(Just in Time) Compilation [Default]:
• Linking functions generated at run-time.
• AoT(Ahead of Time) Compilation:
• Linking functions generated at your build.
• You can use compiler-cli(ngc)
Slide 12
Slide 12 text
Demonstration of AoT
Slide 13
Slide 13 text
Beyond the AoT
Slide 14
Slide 14 text
bundle.js, it’s too large
Slide 15
Slide 15 text
Limitation of JavaScript
minifier
• Static types allow more optimization
• TypeScript(statically type language)
• Google Closure Compiler has annotated-
based minifier
• So, TypeScript + AoT + Closure Compiler..?
https://github.com/angular/tsickle