0.10.2 • Published 12 months ago

@nanostores/persistent v0.10.2

Weekly downloads
-
License
MIT
Repository
github
Last release
12 months ago

Nano Stores Persistent

A smart store for Nano Stores state manager to keep data in localStorage and synchronize changes between browser tabs.

  • Small. from 281 bytes (minified and brotlied). Zero dependencies. It uses Size Limit to control size.
  • It has good TypeScript.
  • Framework agnostic. It supports SSR. localStorage can be switched to another storage.
import { persistentAtom } from '@nanostores/persistent'

export const locale = persistentAtom('locale', 'en')

Made at Evil Martians, product consulting for developer tools.


Docs

Read full docs here.