Open vishalmindinventory opened 6 years ago
I believe that the issue is in a way you define Vue component method. It should be like this:
export default {
methods: {
auth(provider) {
this.$auth.authenticate(provider) { ... };
}
}
}
As for SSR support, this will be provided in next release.
Ok. Thanks!
@dgrubelic Below is my code for twitter integration. I am using SSR with webpack.
login.vue `<b-link class="tw" @click="auth('twitter')"> Twitter
export default { methods: { auth: function (provider) { this.$auth.authenticate(provider).then(function () { console.log("in") }) }, } }`
app.js `if (typeof window !== 'undefined') { const VueAuthenticate = require('vue-authenticate')
}`
Version history Node version: 10.11.0 npm version: 6.2.0 vue version: 3.0.0 webpack: 3.8.1
I had used condition because, I am getting error i.e. window is not defined. Let me if anything is missing.
Thanks in advance.