npm / dependency-cruiser
dependency-cruiser
What changed in dependency-cruiser 17 to 18, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-17.
3 breaking1 deprecations8 new APIs and options5 performance9 behavior and defaults7 tooling8 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli initdependency-cruiser 1820 changes
Breaking changes 2
The dot-webpage reporter is no longer experimental and replaces the name x-dot-webpage.
Support for Node.js 20 and 25 was dropped, so projects using those versions must upgrade.
Deprecations 1
The depcruise-baseline command is deprecated in favor of dependency-cruiser --baseline.
New APIs and options 5
The new baseline-mode value format sorts the baseline so future diffs are easier to read after manual edits.
Set baseline.staleEntriesSeverity to error to make the err, null, azure-devops and teamcity reporters exit with a non-zero code when the baseline contains stale entries.
Exposes baseline functionality as a regular dependency-cruiser option, with the same functionality as depcruise-baseline.
Updating the baseline can now remove fixed violations without adding new ones.
Configurations can now be written in TypeScript.
Behavior and default changes 6
Import extraction now supports imports inside module and namespace blocks.
The err, err-html and markdown reporters now show the number of stale entries in the baseline.
Baseline updates now show how many violations are new, unchanged, or removed.
Nested .gitignore files are now taken into account.
dependency-cruiser now warns at runtime when TypeScript, Babel, or SWC is needed but a usable compiler is not present.
The report's table heads are now sticky.
Tooling 3
The markdown report adds a baseline stale table.
The swc compiler can now parse tsx and jsx.
The swc compiler now recognizes type-only imports.
Fixes and other changes 3
Svelte components that use top-level await can now be compiled.
Finds the SWC Visitor when Bun hands over the default export, fixing extraction in that case.
The graph summary is now more deterministic.
dependency-cruiser 1721 changes
Breaking changes 1
AJV is no longer a runtime dependency, reducing dependency management and making installation faster.
New APIs and options 3
Adds a configuration option for err-* and markdown reporters to show unresolved module names in the to-part of violations.
Adds the ancestor matcher for dependency-cruiser configuration.
Adds a suffix option for clickable links.
Performance 5
The reachables algorithm runs 1.3–1.5x faster, potentially improving runs with reachables in the rule set.
Regex compilations are cached throughout dependency-cruiser, making validation 1.5–2.5x faster.
JSON schemas are pre-compiled at build time, making the validation step 10x faster.
Performance optimizations make runs on TypeScript sources faster.
Algorithm updates improve performance.
Behavior and default changes 3
Enriches violations with the unresolved module name and the dependency types.
Dependents are now analyzed when --reaches or --focus are the only reason to do so.
The ndjson listener output now includes runId and user and system totals.
Tooling 4
Adds a basic consistency check for TypeScript and Babel features against transpiler availability.
Dependency-cruiser can now be used with TypeScript v6.
Dependency-cruiser now detects imports done with process.getBuiltinModule.
Working with bun modules is easier; bun modules were already supported.
Fixes and other changes 5
Retains Svelte 5+ dependencies used exclusively outside <script> sections during extraction.
The flat dot reporter now respects collapse patterns.
Extraction works again when TypeScript is not installed.
Fixes tsconfig not working when using the API.
Calls ITranspilerWrapper.isAvailable() correctly in the Svelte pre process.