Dashboard › cli › SQLite dual-driver architecture and WAS…
01a08736-4e89-734f-9032-40bafb766d99| Project | Hits | Last recalled |
|---|---|---|
| opencode-lore | 2 | 12h ago |
Support Node 18+ through two SQLite drivers: built-in node:sqlite on Node 22.15+ and node-sqlite3-wasm on older supported versions. The adapter must handle incompatible bindings: the WASM driver always spreads parameters, maps undefined to null, and needs a manual transaction wrapper. Externalize the WASM module during builds, ship its .wasm asset, and resolve it through locateFile. Build packages on Node 22.15+ and smoke-test the supported Node matrix so CI exercises the fallback. Never bundle the WASM driver into the standalone SEA binary. When changing this layer, inspect actual SQLite usage and preserve automatic driver selection after tests to avoid leaked forced state.