Get started with vue-ls CDN
MIT licensed
Vue-LS is a Vue.js plugin for easy local storage management.
Tags:- localstorage
- local-storage
- vue-localstorage
- vuejs-localstorage
- vue-local-storage
- vuejs-local-storage
- vue-ls
- vue
- vuejs
- vue-plugin
- watch
- es6-modules
Stable version
Copied!
How to start using vue-ls CDN
<template>
<div id="app">
<button @click="increment">Increment</button>
<button @click="load">Load from local storage</button>
<p>Count: {{ count }}</p>
</div>
</template>
<script>
import VueLS from 'vue-ls';
export default {
data() {
return {
count: 0,
};
},
created() {
this.$ls.load(this, 'count', 0);
},
methods: {
increment() {
this.count++;
this.$ls.set(this, 'count', this.count);
},
load() {
this.count = this.$ls.get(this, 'count', 0);
},
},
mounted() {
Vue.use(VueLS);
},
};
</script>
Copied!
Copied!
All versions
1.0.0
1.0.1
1.0.10
1.0.2
1.0.3
1.0.4
1.0.5
1.0.6
1.0.7
1.0.8
1.0.9
1.1.0
1.1.1
1.2.0
1.2.1
1.2.2
1.2.3
1.2.4
1.2.5
1.2.6
1.2.7
2.0.0
2.0.1
2.0.2
2.1.0
2.1.1
2.1.2
2.1.3
2.1.4
2.1.5
2.1.6
2.1.7
2.2.0
2.2.10
2.2.12
2.2.13
2.2.14
2.2.15
2.2.16
2.2.17
2.2.18
2.2.2
2.2.21
2.2.3
2.2.4
2.2.5
2.2.6
2.2.7
2.2.8
2.3.0
2.3.3
2.4.0
2.4.1
3.0.0
3.0.3
3.0.4
3.0.5
3.1.0
3.2.0
3.2.1
3.2.2
4.0.0
4.1.0
*** 4.2.0