Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

this.$auth.token manual #633

Closed
nunob87 opened this issue Feb 22, 2021 · 2 comments
Closed

this.$auth.token manual #633

nunob87 opened this issue Feb 22, 2021 · 2 comments

Comments

@nunob87
Copy link

nunob87 commented Feb 22, 2021

upgrade from version 2 to 4, but keep the vue 2 js, I can't get this to work, how can I activate the token manually?

this. $ auth.token ('bearer', res.data.api_token)

thanks

@websanova
Copy link
Owner

Did you follow upgrade guide?

https://websanova.com/docs/vue-auth/upgrades/3x-4x

@nunob87
Copy link
Author

nunob87 commented Feb 22, 2021

I have it running on an application, only I have another application where there is only login if there is a token, there is a token there is no token there is no session, I did this manually to keep the same plugin since this second application reuses most of the other's files

this. $ auth.token ('bearer', res.data.api_token), but now making this line, he does not keep the token in orders.

this. $ auth.login ({
params: this.form,
remember: false,
autoLogin: true,
staySignedIn: false,
fetchUser: false
}). then ((res) => {
this. $ auth.token ('bearer', res.data.api_token)
}, () => {})

thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants