Closed hank-hong closed 7 years ago
You need to use the session
driver instead. e.g.
locker.driver('session').put('user', user);
See here - https://github.com/tymondesigns/angular-locker#switching-storage-drivers
Hello @tymondesigns
Thanks for your quickly response, I got your point, but I also have tried this solution. If I used locker.driver('session').put('user', user); the value will be lost in other tab in the same browser. Do you know this issue?
I want to save the use info in the browser, ex: I can open many tabs in the same browser.
The version is angular-locker "2.0.4". I put the value in storage, for example:
After I close the browser and reopen, input the url to enter in page, I found the value is still in storage. storage.has('user') == true
Could you please tell me how to set the configuration to make the value clear after I close the browser?
Thank you.