Skip to main content

Module wasm_bridge

Module wasm_bridge 

Source
Expand description

WASM-bindgen API surface — exposes Qualia engine functions to JavaScript. Split into domain submodules; pub use * keeps every wasm_bridge::fn path stable.

Structs§

BackupManifest
BackupStorePolicy
BackupVerifyResult
DeviceStoragePolicy
PrimaryStorePolicy
RecoveryPolicy
StoragePlan
StoragePlanInput

Constants§

BACKUP_IDB_KEY
BACKUP_IDB_NAME
IndexedDB database id used by the JS host to remember the backup folder handle.
BACKUP_IDB_STORE
BACKUP_SUBDIR
Suggested subdirectory name inside the user-picked backup folder.
DEFAULT_BACKUP_RETENTION
Soft target: keep at least this many dated backup snapshots.
MIN_PRIMARY_HEADROOM_BYTES
Minimum free bytes before the host should refuse a large ingest.
VAULT_MANIFEST_NAME
Manifest file inside the OPFS vault.
WEBCIVICS_OPFS_DIR
OPFS directory name under navigator.storage.getDirectory().

Functions§

device_storage_policy
Canonical policy document for Civics / mobile hosts.
plan_device_storage
Decide whether the host should persist, link a backup folder, or run a backup.
verify_backup_manifest
Fail-closed checks for a backup snapshot manifest (host supplies SHA-256 hex).