Skip to content

createOpfsPgwasm

createOpfsPgwasm<E>(options): Promise<OpfsPgwasm<E>>

Defined in: packages/pgwasm/src/opfs/create.ts:58

Construct the only supported OPFS-repacked/pgwasm pairing.

pgwasm always awaits the filesystem sync (relaxedDurability: false). Physical durability is selected once, here, by the store’s durability option and is never delegated to the database option. A strict sync completes successful database initialization before return. Closing the database closes the store: its build releases the filesystem (closeFs) on every close, a failed one included.

E extends Readonly<Record<string, ServerExtension | Extension<unknown>>> = Record<never, never>

CreateOpfsPgwasmOptions<E>

Promise<OpfsPgwasm<E>>