首页 > 解决方案 > Google 登录错误 - 用户取消登录或未完全授权

问题描述

使用“angularx-social-login”npm 模块进行登录,当运行 ionic serve cmd 但在设备中不工作时,它在浏览器上工作正常。

显示错误:

ERROR: Uncaught (in promise): User cancelled login or did not fully authorize.
this.OAuth.signIn(GoogleLoginProvider.PROVIDER_ID).then(res => { 
 console.log(res);
   }):

标签: angularionic-framework

解决方案


根据以下链接,我认为这是关于 angularx-social-login 的一个未解决问题:

https://github.com/abacritt/angularx-social-login/issues/6

https://forum.ionicframework.com/t/is-there-a-way-to-integrate-facebook-google-login-in-ionic-pwa/98772

如果您使用 Ionic 来实现使用 Google 登录,Ionic 已经有本地插件可以做到这一点

https://ionicframework.com/docs/native/google-plus


推荐阅读