AngularJS template

From Wiki @ Karl Jones dot com
Revision as of 13:12, 31 December 2016 by Karl Jones (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

In AngularJS, a template is HTML which tells AngularJS how to render a component.

Templates include data bindings as well as other components and directives.

Angular 2 leverages native DOM events and properties.

Angular 2 leverages shadow DOM, helps with view encapsulation (e.g. styles applied to component).

Best practice: put template in component metadata.

See also