【发布时间】:2018-02-09 16:21:41
【问题描述】:
Firebase API 强制我为 verifyEmail 和 resetPassword 使用以下链接结构:
http://www.example.com/action?mode=verifyEmail?code=123
http://www.example.com/action?mode=resetPassword?code=123
只有“http://www.example.com/action”是可替换的。我的问题是我尝试将它集成到我的 Vue 路由器中的 2 个不同条目中,这些条目链接到 2 个不同的组件。
我试过了,但页面都是空白的。
{
path: '/action?mode=verifyEmail',
name: 'VerifyEmail',
component: VerifyEmail
},
{
path: '/action?mode=resetPassword',
name: 'Reset Password',
component: ResetPassword
},
例如,如果我这样做,那么它会起作用(但仅适用于我调用的那个):
{
path: '/auth',
name: 'Reset Password',
component: ResetPassword
},
当然我可以这样做,然后我可以在我调用的组件中管理它,但是在路由中处理它更干净(如果可能的话)。
非常感谢
【问题讨论】:
标签: firebase vue.js vuejs2 vue-router