What is the difference between `value` attribute and `ng-value` attributes in angularjs
问题 What is the difference between value and ng-value attributes in angularjs templates? If I use ng-if on the field using value attribute it works properly but if I change the attribute value to ng-value it stops working. example 1 // it works <input type='radio' ng-model='difficulty' value='hard'/> <div ng-if="difficulty == 'hard'"> <p>difficulty is hard</p> </div> Example 2 // it doesn't work <input type='radio' ng-model='level' ng-value='hard'/> <div ng-if= "level == 'hard'" > <p>level is