Replies: 1 comment 3 replies
|
@jsmunroe Thanks a lot for your contribution, Please give me sometime to go through your code and run a test against our usecases! In the meantime, You can create a PR to the development, Thank you for your contribution |
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
I had to fork this repo. Here is my fork. My team is using
sessionStorageinstead oflocalStoragebecause we want the data to live only for the duration of the user's session.Both of these types are
Storagetypes and so I generalized yourSessionLocalStorageclass into aSessionStorageclass that takes aStorageobject in its constructor. This way thesessionLocalStorageinstance is instantiated like this...I left
secureLocalStorageas the default export to avoid breaking changes and addedsecureSessionStorageas an auxiliary export. This instance is instantiated as such...sessionStorageis supported in 95.91% of browsers and adds a lot of flexibility when it comes to life spans of client-side data. Feel free to incorporate this change into your own repository, just let me know when you do so I can move my project back over to your package.Thanks for the great code. Much luck.
All reactions