OpfsWorker
Runs the worker side of the browser SQLite WASM client that stores data in OPFS.
This module opens @effect/wa-sqlite with the OPFS access-handle VFS, then
listens on a MessagePort-compatible port for the protocol used by
SqliteClient. It sends a ready message, executes SQL messages, imports and
exports database bytes, forwards update-hook notifications, and closes when
requested. It is meant to run in a dedicated worker or a SharedWorker.
Models
OpfsWorkerConfig interface
Added in v4.0.0
Source
Configuration for the SQLite OPFS worker, including the message port used for the client protocol and the OPFS database name to open.
Signature
interface OpfsWorkerConfig { readonly dbName: string; readonly port: EventTarget & Pick<MessagePort, "postMessage" | "close"> & Partial<Pick<MessagePort, "start">>;}