Twelve self-contained pages, each demonstrating one feature with a guided tour, a how-it-works diagram, and an automated test suite you can run in the browser.
Each page is a complete HTML file backed by pkg/mqdb_wasm.js — no build step needed beyond wasm-pack build --target web.
Basic CRUD — create / read / update / delete and the _version field.Filtering — filter operators, sort, pagination, projection.Schema — typed fields, required + default.Constraints — UNIQUE, NOT NULL, FK cascade/restrict.Subscriptions — reactive change events, consumer groups.Persistent then Encrypted — IndexedDB and AES-GCM at rest.Create / read / update / delete and merge semantics. Auto-assigned ids and _version bumps on every write.
eq/ne/gt/lt/gte/lte/glob/null filters plus sort, pagination, projection. Multi-filter is AND.
count(opts) returns just the matching row count, without loading the rows.
Streaming iteration — nextItem() / nextBatch() over a filter result without materializing the array.
Declare field types, required fields, and default values. MQDB validates every write.
UNIQUE, NOT NULL, FOREIGN KEY with CASCADE / RESTRICT / SET NULL on delete.
Declare posts.author → users once; read with includes to get the joined record.
Data survives reloads. Toggle between in-memory and IndexedDB modes and watch the difference.
Passphrase-derived key, per-record encryption. Lock/unlock flow with live ciphertext view.
createSync/listSync/… no-await mirror of CRUD for the memory backend. Includes perf comparison.
Everything MQDB does, addressed by MQTT-style topic — the same surface the networked broker uses.
# Build the WASM package cd crates/mqdb-wasm wasm-pack build --target web # Serve the examples cd examples python3 -m http.server 8080 # Open http://localhost:8080/