localstorage-time
v1.0.0
Published
localStorage 支持设置过期时间
Downloads
3
Readme
localStorage 支持设置过期时间
npm i localstorage-time -S
import { Storage } from 'localstorage-time';
// 10s 后过期
Storage.set('key', 123, Date.now() + 1000 * 10);
Storage.get('key');