🚀 Socket Launch Week Day 5:Introducing Repository Access Permissions and Custom Roles.Learn more
Sign In

vuex-uniapp-persistence

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vuex-uniapp-persistence

uniapp vue2 vuex 持久化

latest
Source
npmnpm
Version
1.0.1
Version published
Maintainers
1
Created
Source

快速上手

安装

npm i vuex-uniapp-persistence

引入

store.js 引入

// 页面路径:store/index.js
import Vue from "vue";
import Vuex from "vuex";
import persistence from "./plugins/persistence";
Vue.use(Vuex);
const store = new Vuex.Store({
  // 使用模块
  plugins: [persistence()],
});
export default store;

api

persistence(key)

key 是你设置 本地存储的 key 的名称,如果不传,默认就是 vuex-uniapp-persistence

更新日志

1.0.1

将本地存储完全替换 state 修改为 合并本地存取和 state 融合到 vuex 中

联系我

  • yeah126139163@163.com
  • https://github.com/itcastWsy/vuex-uniapp-persistence

Keywords

uniapp

FAQs

Package last updated on 03 Dec 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts