AngularFire2 Authentication Error: First argument “email” must be a valid string

前提是你 提交于 2019-12-09 08:35:38

The signature for af.auth.login() is one object with two properties:

// Email and password
af.auth.login({
  email: 'email@example.com',
  password: 'password',
},
{
  provider: AuthProviders.Password,
  method: AuthMethods.Password,
})

https://github.com/angular/angularfire2/blob/master/docs/5-user-authentication.md

... if you're using username and password, then you'll have to call af.auth.login() with the user's credentials.

af.auth.login({ email: 'email', password: 'pass' });

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!