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

Allow parse and stringify extension #120

Open
DaddyWarbucks opened this issue Dec 7, 2022 · 0 comments
Open

Allow parse and stringify extension #120

DaddyWarbucks opened this issue Dec 7, 2022 · 0 comments

Comments

@DaddyWarbucks
Copy link
Contributor

I would like to see two methods added to this class parse(string) and stringify(data). And those methods should just return their JSON method by default and should be used to parse/stringify the store.
The following two places would be updated to use this.parse or this.stringify

This would allow the user to extend the service class and use their own parser. My specific example for this is using JSON Compression to compress the store before storing it in storage and decompress the store when pulling it out of storage.

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

1 participant