{"id":94,"date":"2016-03-20T13:41:39","date_gmt":"2016-03-20T13:41:39","guid":{"rendered":"http:\/\/windows.emacslisp.com\/?p=94"},"modified":"2016-03-20T13:44:52","modified_gmt":"2016-03-20T13:44:52","slug":"angular-js-compile-document-to-tree-struction","status":"publish","type":"post","link":"http:\/\/windows.emacslisp.com\/index.php\/2016\/03\/20\/angular-js-compile-document-to-tree-struction\/","title":{"rendered":"Angular.js compile document to tree struction"},"content":{"rendered":"<p>the first step of angular.js is to compile document to element and childnode. this struction is similar with DOM.<\/p>\n<p>module is key concept of angular.js. what is angular.js module.<br \/>\nA module is a collection of services, directives, controllers, filters, and configuration information.<\/p>\n<p>for example:<\/p>\n<pre lang=\"javascript\" line=\"1\">\r\nvar element = $compile('<p>{{total}}<\/p>')(scope);\r\n <\/pre>\n<p>it calls compile(&#8230;) function to find &#8216;ng-module&#8217;, &#8216;ng-controller&#8217;, something like &#8216;ng-xxxx&#8217; and so on.<\/p>\n<p>shortly, this steps compile html to tree, and Addmodule to lists, AddDirectives to directives lists.<\/p>\n<p>this is critical steps of beginning. I will add more example and code to explain.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>the first step of angular.js is to compile document to element and childnode. this struction is similar with DOM. module is key concept of angular.js. what is angular.js module. A module is a collection of services, directives, controllers, filters, and &hellip; <a href=\"http:\/\/windows.emacslisp.com\/index.php\/2016\/03\/20\/angular-js-compile-document-to-tree-struction\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5],"tags":[],"_links":{"self":[{"href":"http:\/\/windows.emacslisp.com\/index.php\/wp-json\/wp\/v2\/posts\/94"}],"collection":[{"href":"http:\/\/windows.emacslisp.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/windows.emacslisp.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/windows.emacslisp.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/windows.emacslisp.com\/index.php\/wp-json\/wp\/v2\/comments?post=94"}],"version-history":[{"count":3,"href":"http:\/\/windows.emacslisp.com\/index.php\/wp-json\/wp\/v2\/posts\/94\/revisions"}],"predecessor-version":[{"id":97,"href":"http:\/\/windows.emacslisp.com\/index.php\/wp-json\/wp\/v2\/posts\/94\/revisions\/97"}],"wp:attachment":[{"href":"http:\/\/windows.emacslisp.com\/index.php\/wp-json\/wp\/v2\/media?parent=94"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/windows.emacslisp.com\/index.php\/wp-json\/wp\/v2\/categories?post=94"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/windows.emacslisp.com\/index.php\/wp-json\/wp\/v2\/tags?post=94"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}