UNPKG

prefer-storage

Version:

1. key: 键名不唯一 2. value: 只能存储string类型 3. time: 没有过期时间 4. handle data: 不能对数据统一处理

9 lines (8 loc) 591 B
import { type IStrategyFn, type IType } from '@/types'; export declare const StorageStrategy: Record<IType, IStrategyFn<any>>; export declare const getNewKey: <T extends string>(name: string, key: T) => string; export declare const getIdbValue: (keyKey: string, keyValue: string) => Recordable<any>; export declare const getValueType: (value: string) => string; export declare const isDue: (time: string, expire: number) => boolean; export declare const getFullPath: () => string; export declare const handleGetJSONData: (type: string, value: any, reject: (reason?: any) => void) => string;