[generated] sandpack files from: codesandbox-client

This commit is contained in:
Will Chen
2025-04-12 00:09:50 -07:00
parent 4b641a3303
commit a618ec3f56
442 changed files with 393342 additions and 0 deletions

View File

@@ -0,0 +1,31 @@
/// <reference types="node" />
import { BFSCallback, FileSystemOptions } from '../core/file_system';
import { SyncKeyValueStore, SimpleSyncStore, SyncKeyValueFileSystem, SyncKeyValueRWTransaction } from '../generic/key_value_filesystem';
/**
* A synchronous key-value store backed by localStorage.
*/
export declare class LocalStorageStore implements SyncKeyValueStore, SimpleSyncStore {
name(): string;
clear(): void;
beginTransaction(type: string): SyncKeyValueRWTransaction;
get(key: string): Buffer | undefined;
put(key: string, data: Buffer, overwrite: boolean): boolean;
del(key: string): void;
}
/**
* A synchronous file system backed by localStorage. Connects our
* LocalStorageStore to our SyncKeyValueFileSystem.
*/
export default class LocalStorageFileSystem extends SyncKeyValueFileSystem {
static readonly Name = "LocalStorage";
static readonly Options: FileSystemOptions;
/**
* Creates a LocalStorageFileSystem instance.
*/
static Create(options: any, cb: BFSCallback<LocalStorageFileSystem>): void;
static isAvailable(): boolean;
/**
* Creates a new LocalStorage file system using the contents of `localStorage`.
*/
private constructor();
}