diff options
| author | Andrew Peterson | 2013-06-26 00:19:50 -0600 |
|---|---|---|
| committer | Pete Bacon Darwin | 2013-06-27 21:20:56 +0100 |
| commit | 083159ebbe75badc630436a176f29a4cda8c6296 (patch) | |
| tree | 450e7bb557528c064c45c921939a55bcb653c05e /src/ng/directive/ngBind.js | |
| parent | 32e440cffc7c321002aed5f5a857dded7afbd49f (diff) | |
| download | angular.js-083159ebbe75badc630436a176f29a4cda8c6296.tar.bz2 | |
docs(ngBind): clarify some of the writing
Diffstat (limited to 'src/ng/directive/ngBind.js')
| -rw-r--r-- | src/ng/directive/ngBind.js | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/ng/directive/ngBind.js b/src/ng/directive/ngBind.js index f75fb54b..f1cf4c70 100644 --- a/src/ng/directive/ngBind.js +++ b/src/ng/directive/ngBind.js @@ -12,10 +12,9 @@ * Typically, you don't use `ngBind` directly, but instead you use the double curly markup like * `{{ expression }}` which is similar but less verbose. * - * One scenario in which the use of `ngBind` is preferred over `{{ expression }}` binding is when - * it's desirable to put bindings into template that is momentarily displayed by the browser in its - * raw state before Angular compiles it. Since `ngBind` is an element attribute, it makes the - * bindings invisible to the user while the page is loading. + * It is preferrable to use `ngBind` instead of `{{ expression }}` when a template is momentarily + * displayed by the browser in its raw state before Angular compiles it. Since `ngBind` is an + * element attribute, it makes the bindings invisible to the user while the page is loading. * * An alternative solution to this problem would be using the * {@link ng.directive:ngCloak ngCloak} directive. @@ -61,10 +60,11 @@ var ngBindDirective = ngDirective(function(scope, element, attr) { * * @description * The `ngBindTemplate` directive specifies that the element - * text should be replaced with the template in ngBindTemplate. - * Unlike ngBind the ngBindTemplate can contain multiple `{{` `}}` - * expressions. (This is required since some HTML elements - * can not have SPAN elements such as TITLE, or OPTION to name a few.) + * text content should be replaced with the interpolation of the template + * in the `ngBindTemplate` attribute. + * Unlike `ngBind`, the `ngBindTemplate` can contain multiple `{{` `}}` + * expressions. This directive is needed since some HTML elements + * (such as TITLE and OPTION) cannot contain SPAN elements. * * @element ANY * @param {string} ngBindTemplate template of form |
