【发布时间】:2019-07-25 12:45:51
【问题描述】:
我正在关注一个博客,该博客向我们展示了如何使用 vue-authenticate 和 django restframework 进行社交身份验证。
但是,该博客使用了一些我没有使用的社交身份验证框架。我正在使用 django-rest-auth 包。
我尝试进行相应的设置,但遇到了一些问题。
redirectUri: 'http://localhost:8080/',
url: 'http://localhost:8000/rest-auth/google/',
上面的代码显示了我根据 vue-authenticate 文档放置在提供程序设置中的链接
this.$auth.authenticate('google', {provider: "google-
oauth2"}).then(function (response)
以上代码根据我从博客中复制的 vue-authenticate 中的文档显示了认证方法。这是我收到验证失败的错误消息。
我到底做错了什么?我似乎无法确定问题所在。
【问题讨论】:
标签: django vue.js django-rest-framework django-rest-auth