@topazden/vue-storage
v0.2.4
Published
vuejs local-storage util
Downloads
16
Readme
vue-storage
A localStorage util in vuejs.
Usage
npm i @topazden/vue-storage -S
In main.js:
import { createApp } from 'vue'
import Root from './App.vue'
import { VueStorage } from '@topazden/vue-storage'
const app = createApp(Root)
app.use(VueStorage)
app.mount('#app')
In vue files:
this.$storage.set('x-token', 'test-token')
In utils.js:
import { Storage } from '@topazden/vue-storage'
storage.set('x-token', 'test-token')