Skip to content

Instantly share code, notes, and snippets.

@awerlang
Last active March 6, 2017 14:27
Show Gist options
  • Star 4 You must be signed in to star a gist
  • Fork 3 You must be signed in to fork a gist
  • Save awerlang/fea0da3b61cf1f4b1a8a to your computer and use it in GitHub Desktop.
Save awerlang/fea0da3b61cf1f4b1a8a to your computer and use it in GitHub Desktop.
Angular.js directives sorted by priority
/*
I've compiled a list of angular directives according to their priorities (from most priority to lesser priority).
Also, terminal property is included for each directive that asserts it
*/
ng-switch 1200
ng-repeat 1000 terminal
ng-if 600 terminal
ng-controller 500
ng-init 450
ng-include 400 terminal
ng-list 100
ng-value 100
select 100
disabled 100
checked 100
readonly 100
selected 100
open 100
ng-pattern 100
href 99
src 99
srcSet 99
ng-model 1
ng-options - terminal
script - terminal
@mikesigs
Copy link

mikesigs commented Aug 7, 2015

Just what I was looking for. This should be in the Angular docs somewhere. Thank you!

@mikesigs
Copy link

mikesigs commented Aug 7, 2015

Check out my fork. I updated the list with more directives.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment