{"id":25055,"library":"caql-js-compiler","title":"CaQL JS Compiler","description":"A JavaScript library that compiles CaQL (Calypso Query Language) queries into executable JavaScript functions. Current stable version is 0.5.0, released with no recent updates (likely abandoned). It allows filtering, sorting, and projecting arrays of objects using a SQL-like query syntax. Compared to libraries like Sequelize or Knex, this is a client-side query engine for in-memory data, not a database ORM. It provides a simple compiler and executor pattern, but lacks TypeScript definitions, ESM support, and has seen no maintenance since its release.","status":"abandoned","version":"0.5.0","language":"javascript","source_language":"en","source_url":"git://github.com/kevinswiber/caql-js-compiler","tags":["javascript","caql","calypso","compiler"],"install":[{"cmd":"npm install caql-js-compiler","lang":"bash","label":"npm"},{"cmd":"yarn add caql-js-compiler","lang":"bash","label":"yarn"},{"cmd":"pnpm add caql-js-compiler","lang":"bash","label":"pnpm"}],"dependencies":[],"imports":[{"note":"CommonJS only; no default export.","wrong":"const JSCompiler = require('caql-js-compiler').default;","symbol":"JSCompiler","correct":"const JSCompiler = require('caql-js-compiler');"},{"note":"ESM via default import works with bundlers, but package has no ESM declaration.","wrong":"import { JSCompiler } from 'caql-js-compiler';","symbol":"JSCompiler","correct":"import JSCompiler from 'caql-js-compiler';"}],"quickstart":{"code":"const JSCompiler = require('caql-js-compiler');\n\nconst data = [\n  { name: 'Alice', age: 30 },\n  { name: 'Bob', age: 25 },\n  { name: 'Charlie', age: 35 }\n];\n\nconst compiler = new JSCompiler();\nconst query = 'select name, age where age >= 30 order by age desc';\nconst results = compiler.compile(query).execute(data);\nconsole.log(results);\n// [ { name: 'Charlie', age: 35 }, { name: 'Alice', age: 30 } ]\n","lang":"javascript","description":"Basic usage: query an array of objects with select, where, and order by clauses."},"warnings":[{"fix":"Consider using a maintained alternative like 'sift.js' for querying arrays.","message":"Package has not been updated since 2014; may contain unpatched vulnerabilities.","severity":"deprecated","affected_versions":"all"},{"fix":"Use require() or a bundler with CommonJS interop.","message":"Requires CommonJS (Node.js); no ES module build provided.","severity":"gotcha","affected_versions":"0.5.0"},{"fix":"Assign the result to a new variable.","message":"`execute()` returns an array; it does not modify the original data.","severity":"gotcha","affected_versions":"all"},{"fix":"Ensure field names match object property names.","message":"Field names from CaQL SELECT are case-sensitive and must match object keys exactly.","severity":"gotcha","affected_versions":"all"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"Run `npm install caql-js-compiler`","cause":"Package not installed.","error":"Cannot find module 'caql-js-compiler'"},{"fix":"Use `const JSCompiler = require('caql-js-compiler');` and then `new JSCompiler()`.","cause":"Incorrect import (maybe used .default).","error":"compiler.compile is not a function"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}