I work in a small team, creating in AngularJS and trying to maintain some basic standards and best practices; especially considering that we are relatively new with Angular.
My question is about directives. More precisely, restrict parameters.
Some of us use restrict: 'E' , having <my-directive></my-directive> in html.
Others use restrict: 'A' and have <div my-directive></div> in html.
Then of course you can use restrict: 'EA' and use any of the above.
This does not really matter at the moment, although when this project is as big as it is going to be, I would like someone to look at it to easily understand what is happening.
Are there any pros / cons for an attribute or element capable of doing something?
Are there any pitfalls we need to know if you select the say attribute above the attribute?
javascript html angularjs
Darren Apr 22 '14 at 13:24 2014-04-22 13:24
source share