AngularJS error: TypeError: v2.login is not a function

前端 未结 8 933
暖寄归人
暖寄归人 2021-01-17 07:49

I would like to call the login function when I click the login button but keep getting the error message in the title. Can someone point out the error in my script?

8条回答
  •  时光说笑
    2021-01-17 08:11

    It may be a late answer by me. But It working for me

    Check form name you set e.g. ng-form="login"

    and function name e.g. ng-click="login()"

    Then it will not work . You have to change one of them. e.g. ng-form="loginForm"

提交回复
热议问题