Difference between revisions of "AngularJS template"
From Wiki @ Karl Jones dot com
Karl Jones (Talk | contribs) (Created page with "In AngularJS, a '''template''' provides HTML. == See also == * AngularJS * AngularJS component * AngularJS directive * JavaScript library * Web applica...") |
Karl Jones (Talk | contribs) |
||
Line 1: | Line 1: | ||
− | In [[AngularJS]], a '''template''' | + | 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 [[AngularJS metadata|metadata]]. | ||
== See also == | == See also == |
Latest revision as of 13:12, 31 December 2016
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.