diff options
Diffstat (limited to 'docs/content/guide')
| -rw-r--r-- | docs/content/guide/directive.ngdoc | 8 | 
1 files changed, 6 insertions, 2 deletions
| diff --git a/docs/content/guide/directive.ngdoc b/docs/content/guide/directive.ngdoc index 9af76221..e80bb8bb 100644 --- a/docs/content/guide/directive.ngdoc +++ b/docs/content/guide/directive.ngdoc @@ -284,14 +284,18 @@ If we simply put a `<my-customer>` element into the HTML, it doesn't work.  <div class="alert alert-waring">  **Note:** When you create a directive, it is restricted to attribute only by default. In order to -create directives that are triggered by element name, you need to use the `restrict` option. +create directives that are triggered by element or class name, you need to use the `restrict` option.  </div>  The `restrict` option is typically set to:  * `'A'` - only matches attribute name  * `'E'` - only matches element name -* `'AE'` - matches either attribute or element name +* `'C'` - only matches class name + +These restictions can all be combined as needed: + +* `'AEC'` - matches either attribure or element or class name  Let's change our directive to use `restrict: 'E'`: | 
