0.0.8 • Published 11 months ago

@where_is_mr_li/storage v0.0.8

Weekly downloads
-
License
ISC
Repository
-
Last release
11 months ago

@where_is_mr_li/storage

对 web storage 的增强和封装

安装依赖

github:

git clone https://github.com/WhereIsMsXi/package-storage.git

cd package-storage

pnpm i

打包

pnpm build

测试

pnpm test

npmjs:

安装

# npm
npm i @where_is_mr_li/storage

# or yarn
yarn add @where_is_mr_li/storage

#or pnpm
pnpm add @where_is_mr_li/storage

使用

// 导入
import { session } from "@where_is_mr_li/storage";

// 存
session.set("key", "sxt");
// 取
const result = session.get("key");
// 删
session.del("key");
// 清空
session.clear();

// 存入 storage 的封装对象
{
  "dataType":"string",
  "content":"sxt",
  "type":"session",
  "datetime":1723219200
}
0.0.8

11 months ago

0.0.7

11 months ago

0.0.1

11 months ago

0.0.3

11 months ago

0.0.2

11 months ago

0.0.5

11 months ago

0.0.4

11 months ago

1.0.0

1 year ago