README
Nano Stores Persistent
A tiny persistent store for Nano Stores state manager. It stores data
in localStorage
and synchronize changes between browser tabs.
- Small. from 308 bytes (minified and gzipped). 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')
Docs
Read full docs on GitHub.