aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorIgor Minar2011-02-06 22:51:33 -0800
committerIgor Minar2011-02-07 23:55:46 -0800
commita6c45c3e66fc0ea3baaa908c90720bcf22c193d7 (patch)
treea8280994905350f2a58e97beced45a50be0c77e2 /src
parente626f95469299ce172a7b86753b10c41dcb91e48 (diff)
downloadangular.js-a6c45c3e66fc0ea3baaa908c90720bcf22c193d7.tar.bz2
add description for ng:controller example
Diffstat (limited to 'src')
-rw-r--r--src/directives.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/directives.js b/src/directives.js
index 5ca7c2ec..545a9e08 100644
--- a/src/directives.js
+++ b/src/directives.js
@@ -46,6 +46,12 @@ angularDirective("ng:init", function(expression){
* @param {expression} expression to eval.
*
* @example
+ * Here is a simple form for editing the user contact information. Adding, removing clearing and
+ * greeting are methods which are declared on the controller (see source tab). These methods can
+ * easily be called from the angular markup. Notice that the scope becomes the controller's class
+ * this. This allows for easy access to the view data from the controller. Also notice that any
+ * changes to the data are automatically reflected in the view without the need to update it
+ * manually.
<doc:example>
<doc:source>
<script type="text/javascript">