- 🐣 introduces orphan detection. See the orphan reference for details. Thanks @adamclerk for suggesting this.
- 🔧 the output json schema changed in a backward incompatible way. For typical use (via the command line) this has no impact - see below for details.
- 👷 node 4 de-support - see below for details.
Breaking change: json output structure slightly updated
impact classification: very low (and medium if you're using the json output or were hacking on the internal API)
On the top level of the json and bare api object output the array of modules is now called modules
in stead of dependencies
. This is more correct and makes both the json and the code instantly
easier to grasp:
after
{
"modules": [
{
"source": "src/extract/derive/circular/dependencyEndsUpAtFrom.js",
"dependencies": [],
"valid": true
},
{
"source": "src/extract/derive/circular/index.js",
"dependencies": [
{
"resolved": "src/extract/derive/circular/dependencyEndsUpAtFrom.js",
"coreModule": false,
"followable": true,
"couldNotResolve": false,
"dependencyTypes": [
"local"
],
"module": "./dependencyEndsUpAtFrom",
"moduleSystem": "cjs",
"matchesDoNotFollow": false,
"circular": false,
"valid": true
}
],
"valid": true
},
{
"source": "src/extract/derive/orphan/isOrphan.js",
"dependencies": [],
"valid": true
}
// ... and possibly more modules
],
"summary": {
// stuff
}
}
before
{
"dependencies": [
{
"source": "src/extract/derive/circular/dependencyEndsUpAtFrom.js",
"dependencies": []
},
{
"source": "src/extract/derive/circular/index.js",
"dependencies": [
{
"resolved": "src/extract/derive/circular/dependencyEndsUpAtFrom.js",
"coreModule": false,
"followable": true,
"couldNotResolve": false,
"dependencyTypes": [
"local"
],
"module": "./dependencyEndsUpAtFrom",
"moduleSystem": "cjs",
"matchesDoNotFollow": false,
"circular": false,
"valid": true
}
]
},
{
"source": "src/extract/derive/orphan/isOrphan.js",
"dependencies": []
}
// ... and possibly more modules
],
"summary": {
// stuff
}
}
Breaking change: node 4 de-support
impact classification: low (unless you're still on node 4)
Per May 1 node 4 is end of life. While dependency-cruiser would probably keep working under node 4 it was a hassle with all kinds of workarounds. If you want to use dependency-cruiser on node 4 you have two options
- use dependency-cruiser@3.1.1 which is the last version supporting node 4
- send me enough money to make the hassle worth its while.
(In most cases the best option is to move to a higher version of node