using directives - ng-show and ng-hide usage in AngularJS -
i aware of difference between ng-show , ng-hide asked question in interview why need ng-hide if have ng-show because know both shows or hides given html element based on values can true or false. reason should favor ng-show on ng-hide or vice versa?
readability.
ng-show="feature.enabled"
more readable ng-hide="!feature.enabled"
. double negations harder understand.
Comments
Post a Comment