Angular 1.x in action now

Post on 06-Jan-2017

45 views 0 download

Transcript of Angular 1.x in action now

Angular 1.x in action now

Andrey Michaliuk @Readdle

Components in 1.5.Xdeclarationslifecycle hooksbindingsrequiretransclude

Declaration component

Bindings structure

Bindings rules

trigger updates for primitive types

array, objects and .. => use immutable.js

$watchers?

and some..

scope.$watch("$ctrl.progress", this.setProgress)

Transclude and slots

Custom elements

<screen-component></screen-component>

Custom elements

Routing

ngRoute -> ui-router -> angular@router/angular1

Routing

Routing

ngRoute -> ui-router -> angular@router/angular1 =>

ui-router

ui-router

Typescript or…

transpile from es6 to es5 - the overhead cost of compiled es2015optional types documentation for you code

Typescript or…

Typescript declaration files

TSD => Typings 1.X => Typings 2.0 => @types from npm

Webpack

slow building over 500 modulesoverhead cost of compiled codeplugins are strangeconfiguration files for project (dev/prod/test env) are really difficult to understand

Looking for

Rollup.js - Material 2 configuration Webpack 2 - noooooClosure compiler

Maybe the end

Andrey Michaliuk Twitter: @andreyctkn Github: @andreyutka