← BYTES
AngularJS·Intermediate·Ref: 5.2.4

In a custom directive definition, what does the restrict option with the value 'E' mean?

Have a question about this video? Mention reference 5.2.4 when you contact us.

a.The directive can only be used as a custom element (its own tag name), not as an attribute or class
b.The directive can only be used as an HTML comment
c.The directive is restricted to admin users only
d.The directive cannot be nested inside another directive
restrict: 'E' tells AngularJS's compiler this directive should only match when used as an element, e.g. <my-directive></my-directive> -- other common values are 'A' (attribute), 'C' (class), and 'M' (comment), and they can be combined like 'AE'.

Find this on YouTube & Instagram

Every BYTES video is tagged with its reference number and topic — search any of these on YouTube or Instagram to find this one:

#BYTES#BYTES524#AngularJS