1.0.0 • Published 5 years ago
@eb3n/pinia-plugin-persist v1.0.0
@eb3n/pinia-plugin-persist
Persists pinia data in localStorage.
Installation
Install the package:
# yarn
yarn add -D @eb3n/pinia-plugin-persist
# npm
npm i -D @eb3n/pinia-plugin-persistImport and install:
// main.ts
import { createPinia } from 'pinia'
import { piniaPersist } from '@eb3n/pinia-plugin-persist'
const pinia = createPinia()
pinia.use(piniaPersist)Enable the plugin per store:
export const useStore = defineStore({
id: '...',
state: () => ({ ... }),
actions: { ... },
getters: { ... },
persist: true
})1.0.0
5 years ago
1.0.0-alpha.0
5 years ago
0.0.2-testing.1
5 years ago
0.0.2-testing.0
5 years ago
0.0.2-testing
5 years ago
0.0.2
5 years ago
0.0.1
5 years ago