UNPKG

@coinmeca/wallet-sdk

Version:
36 lines 1.23 kB
import type { StorageSnapshotState } from "./types"; export type CoinmecaSecureStorageOptions = { codename?: string; emit?: Function; }; export declare const storage: (data?: Record<string, string>, options?: { codename?: string; salt?: string; emit?: Function; }) => { set: (key: string, value: any) => void; get: (key: string) => any; remove: (key: string) => void; clear: () => void; }; export declare class CoinmecaSecureStorage { #private; constructor(storage: any, key?: string, options?: CoinmecaSecureStorageOptions); configure(options?: CoinmecaSecureStorageOptions): void; ready(): void; set(key: string, value: any): void; get(key: string): any; remove(key: string): void; clear(): void; import(storage?: any): boolean; export(): StorageSnapshotState; secure(domain?: string): { set: (key: string, value: any) => void; get: (key: string) => any; peek: (key: string) => any; remove: (key: string) => void; clear: () => void; }; } export declare function getSecureStorage(storage: any, key?: string, options?: CoinmecaSecureStorageOptions): CoinmecaSecureStorage; //# sourceMappingURL=storage.d.ts.map