Chai is a BDD/TDD assertion library for Node.js and the browser. It provides many assertion styles, including assert, expect, and should, and is designed to be paired with any JavaScript testing framework.
Project status
- The repository appears actively maintained, with recent upstream activity (last push on 2026-06-08) and multiple published updates in late 2025 (v6.2.0 to v6.2.2).
- The apparent update cadence is moderately frequent in 2025, with updates landing about 6 to 8 weeks apart (v6.2.0 on 2025-09-27, v6.2.1 on 2025-11-11, v6.2.2 on 2025-12-22).
AI summary generated Today
Recent updates
v6.2.2
5 months agov6.2.2 is a patch release focused on dependency updates, CI workflow adjustments, and a small fix in Chai's closeTo assertion related to BigInt literal usage. The release also updates the build command to suppress legal comments from esbuild output.
v6.2.1
6 months agov6.2.1 is primarily a tooling and dependency update release, with CI workflow actions bumped and multiple devDependencies updated. The code diff also updates documentation for the containSubset assertion and adjusts the build target for the browser bundle. No runtime source changes to the subset comparison algorithm are apparent in the provided diff; most logic changes are limited to comments and test/CI configuration.
v6.2.0
8 months agoChai v6.2.0 adds a new `addChainableMethod` event to its internal plugin event system. The implementation dispatches this event when `chai.util.addChainableMethod` registers a new chainable method, including details about the method being added.
Featuresv6.1.0
8 months agov6.1.0 adds an event system intended to let consumers observe when Chai creates new Assertion methods and properties. The change is implemented by introducing a new shared EventTarget and dispatching events from the addMethod/addProperty utilities, plus a dev dependency bump for tar-fs.
BreakingFeaturesv5.3.3
9 months agov5.3.3 makes two build and release pipeline adjustments: it keeps function/class names in the bundled output and changes how the package is published to npm for v5.* tags. These changes primarily affect debugging/stack traces and npm dist-tag behavior, not the public JavaScript API surface.
v6.0.1
9 months agov6.0.1 makes a build-only change to preserve function and class names in the generated bundle. This is intended to improve debuggability and stack traces without changing the published API.
v6.0.0
9 months agoChai v6.0.0 is packaged to expose a single main entrypoint, `index.js`, removing the previously shipped unbundled `lib/*.js` modules. The published package file list and dependency declarations were adjusted accordingly, with several libraries no longer declared as production dependencies in `package.json`.
Breakingv5.3.2
9 months agov5.3.2 reverts the prior release’s removal of the bundled Chai entrypoint and updates contributor metadata. In the actual code changes, the published package entrypoint is switched back to a bundle produced at build time (index.js), and internal interface modules are rewired to import from the new entry structure.
v5.3.1
9 months agoRelease v5.3.1 is described as a chore to remove the bundled chai build output. The actual diff shows the project also removed the esbuild-based build step and its dependency, and changed the repository/package contents around the root-level chai.js entry file.
Breakingv5.3.0
9 months agoRelease v5.3.0 makes a packaging change in package.json, updating the Node entrypoint for the chai package. Specifically, it switches the package.json "main" field from ./chai.js to ./lib/chai.js.