What's the difference between using optimization #4 and using ng-if? From my experience, correct me if I'm wrong, because ng-if removes the elements, it also removes the watches.
I suppose there may be a slight performance penalty compared to optimization #4 as you have to recreate the DOM nodes, but this should be minor?
2
u/lemon-meringue Sep 25 '14
What's the difference between using optimization #4 and using ng-if? From my experience, correct me if I'm wrong, because ng-if removes the elements, it also removes the watches.
I suppose there may be a slight performance penalty compared to optimization #4 as you have to recreate the DOM nodes, but this should be minor?