forked from angular/code.angularjs.org
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathangular.markup.html
16 lines (13 loc) · 1000 Bytes
/
angular.markup.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
<h1>angular.markup</h1>
<div class="angular-markup"><p>Angular markup transforms the content of DOM elements or portions of the content into other
text or DOM elements for further compilation.</p>
<p>Markup extensions do not themselves produce linking functions. Think of markup as a way to
produce shorthand for a <a href="#!/api/angular.widget"><code>widget</code></a> or a <a href="#!/api/angular.directive"><code>directive</code></a>.</p>
<p>The most prominent example of a markup in Angular is the built-in, double curly markup
<code>{{expression}}</code>, which is shorthand for <code><span ng:bind="expression"></span></code>.</p>
<p>Create custom markup like this:</p><div ng:non-bindable><pre class="brush: js;">
angular.markup('newMarkup', function(text, textNode, parentElement){
//tranformation code
});
</pre></div><p>For more information, see <a href="#!/guide/dev_guide.compiler.markup">Understanding Angular Markup</a>
in the Angular Developer Guide.</p></div>