Disabling form validation

后端 未结 5 1519
暗喜
暗喜 2020-12-20 13:32

Angularjs is running my forms through the FormController (eg tracking pristine, dirty, etc). I don\'t need this functionality; I\'m sure it\'s add

5条回答
  •  刺人心
    刺人心 (楼主)
    2020-12-20 14:05

    UPDATE : This does NOT work ... well at least not in a way you'd like it to. Adding ng-non-bindable to the form or any input breaks ALL binding. So, your ng-model in the inputs won't work anymore. Sorry ....

    ng-non-bindable is the solution to this problem.

    It will prevent AngularJS from seeing the form as a directive. This will make AngularJS ignore the entire form:

    This will make AngularJS ignore one part of a form:

    
    

    You can read a bit about my whining on this issue here. http://calendee.com/preventing-angularjs-from-hijacking-forms/

提交回复
热议问题