here I try to log in using google at nuxt.js, but when I log in with my Google account, the page doesn't move
has anyone experienced the same thing?
I hope someone provides an example of the code. thank you
this.my code login.vue
async loginGoogle() {
try {
let response = await this.$auth.loginWith('google', {})
console.log(response)
} catch (err) {
console.log(err)
}
}
this my code nuxt.config.js
google: {
client_id: 'xxxxxxxxx.apps.googleusercontent.com',
redirect_uri: 'http://localhost:3000',
},
I have take a look at https://auth.nuxtjs.org/api/options.html#redirect
It looks different they use auth
in ther nuxt.config.js
auth: {
redirect: {
login: '/login',
logout: '/',
callback: '/login',
home: '/'
}
}