Open danielalejandromatheus opened 5 years ago
Don't really know the answer to this but I don't think so at this point.
It could be enabled by setting
Vue.use(VueSession, { persist: true })
But I only tried it from the Vue router.js
Sorry the title isn't self explanatory, let me elaborate. In some webs you can toggle a persistence with a 'Remember Me' check, what I meant by "Remember Me" persistence is toggling it programmatically from inside a component,, something like:
login(){
//some login logic
if(this.remember){
this.$session.options.persist = true;
}else this.$session.options.persist = false
this.$session.start()
}
I did understand your question but this doesn't work right?
login(){ //some login logic if(this.remember){ this.$session.options.persist = true; }else this.$session.options.persist = false this.$session.start() }
It doesn't, you can either enable it or disable it only when you install it to your Vue instance like you said above
Okay, persist also means something else in this case.
In the module it provides crosstab/browser instance persistence of the session.
Hey guys, I just got this dependency and so far it's great!
I have a question though, can I make the persistence on the "options" depend on a "remember me" check/token?