AngularJS Directive Restrict A vs E

后端 未结 7 1553
萌比男神i
萌比男神i 2020-12-12 11:43

I\'m working in a small team, building in AngularJS and trying to maintain some basic standards & best practices; especially given we\'re relatively new with Angular.

7条回答
  •  时光说笑
    2020-12-12 12:05

    The restrict option is typically set to:

    • 'A' - only matches attribute name
    • 'E' - only matches element name
    • 'C' - only matches class name
    • 'M' - only matches comment

    Here is the documentation link.

提交回复
热议问题