Skip to content

a Svelte writable store that is persisted to sessionStorage

Notifications You must be signed in to change notification settings

mvolkmann/svelte-session-store

Repository files navigation

svelte-session-store

With normal Svelte stores their value is lost if the user refreshes the browser. This demonstrates persisting changes to a writable store in sessionStorage so they are automatically restored on refresh.

To run this:

  1. npm install
  2. npm run dev
  3. Add some numbers.
  4. Refresh the browser to see that they are not lost.

About

a Svelte writable store that is persisted to sessionStorage

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published