A MongoDB-like query syntax library for JavaScript/TypeScript environments, designed for use with Laf cloud development platform. Version 1.0.0 (beta) provides a fluent API for database operations including CRUD, query commands (eq, gt, in, etc.), update commands (inc, push, etc.), aggregation, and regex queries. It supports both client-side (laf-client-sdk) and server-side (laf) usage, with ESM and TypeScript support. Unlike direct MongoDB drivers, it offers a simplified, promise-based interface with automatic request batching and Laf-specific security features (CVE-2023-48225 fixed in beta.14).
npm install database-qlVerified import paths — ran on the pinned version, not inferred.
Basic CRUD operations using the Laf cloud database with query and update commands.
Upgrade to laf >=1.0.0-beta.14 or apply the security patch.
Use `new Date()` or rely on laf's automatic timestamp insertion.
Access the array via `result.data` instead of treating the result as an array.
Run `npm install database-ql` and ensure version is >=1.0.0.
Use `const db = cloud.database();` where `cloud` is imported from `@lafjs/cloud`.
Ensure you call `cloud.database()` first to get the db instance with commands.
No dependency data recorded yet.