stopslop 1.0.0 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/COMPATIBILITY.md +14 -9
- package/README.md +30 -3
- package/context7.json +3 -2
- package/dist/cli.js +30 -3
- package/dist/index.d.ts +32 -1
- package/dist/index.js +1 -1
- package/dist/src.js +0 -0
- package/docs/configuration.md +8 -3
- package/docs/node-api.md +4 -3
- package/docs/score.md +4 -3
- package/llms.txt +2 -0
- package/package.json +2 -2
- package/schema.json +63 -0
package/COMPATIBILITY.md
CHANGED
|
@@ -1,18 +1,23 @@
|
|
|
1
1
|
# Compatibility
|
|
2
2
|
|
|
3
|
-
Last updated:
|
|
3
|
+
Last updated: 1.1.0
|
|
4
4
|
|
|
5
|
-
StopSlop
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
StopSlop follows Semantic Versioning. Stable surfaces change incompatibly only
|
|
6
|
+
in a major release. Experimental surfaces may change in a minor release; such
|
|
7
|
+
changes are called out in the changelog.
|
|
8
8
|
|
|
9
9
|
| Surface | Tier | Compatibility policy |
|
|
10
10
|
| --- | --- | --- |
|
|
11
|
-
| CLI flags and exit codes |
|
|
12
|
-
| Versioned JSON report |
|
|
13
|
-
| SARIF 2.1.0 report |
|
|
14
|
-
| `stopslop.json` schema |
|
|
15
|
-
| Programmatic Node.js API | Experimental | Exported functions and TypeScript types may change
|
|
11
|
+
| CLI flags and exit codes | Stable | New flags may be added; existing flags and exit code meanings change only in a major release. |
|
|
12
|
+
| Versioned JSON report | Stable | Fields may be added within a `schemaVersion`; removing or changing one increments it and requires a major release. |
|
|
13
|
+
| SARIF 2.1.0 report | Stable | New rules and optional properties may be added; existing required fields remain compatible. |
|
|
14
|
+
| `stopslop.json` schema | Stable | New settings may be added; configuration valid in a 1.x release stays valid in every later 1.x release. |
|
|
15
|
+
| Programmatic Node.js API | Experimental | Exported functions and TypeScript types may change in a minor release. |
|
|
16
|
+
|
|
17
|
+
Findings and scores are not a compatibility surface. Detector fixes, threshold
|
|
18
|
+
calibration, and Knip or Clone Alert updates can change what a release reports
|
|
19
|
+
for the same code; such changes are called out in the changelog. Pin the
|
|
20
|
+
StopSlop version in CI when a gate must not move without a commit.
|
|
16
21
|
|
|
17
22
|
## Runtime support
|
|
18
23
|
|
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# StopSlop
|
|
2
2
|
|
|
3
|
-
[](https://github.com/BaryshevRS/stopslop) [](https://github.com/BaryshevRS/clone-alert) [](https://github.com/BaryshevRS/stopslop/actions/workflows/ci.yml) [](https://www.npmjs.com/package/stopslop)
|
|
4
4
|
<!-- clone-alert badge: pnpm exec clone-alert --minimum-tokens 100 --files src --format shields --no-fail-on-violation -->
|
|
5
5
|
|
|
6
6
|
**Stop AI-generated code from becoming instant legacy.**
|
|
@@ -252,6 +252,31 @@ See [docs/configuration.md](docs/configuration.md) for every field, default, and
|
|
|
252
252
|
Knip workspace example. See [stopslop.example.json](stopslop.example.json) for a
|
|
253
253
|
complete configuration.
|
|
254
254
|
|
|
255
|
+
### Dead-code configuration
|
|
256
|
+
|
|
257
|
+
Knip settings go under `knip` in `stopslop.json`. A project's own `knip.json`,
|
|
258
|
+
`.knip.json`, `knip.config.*` and `package.json#knip` are never read, so an
|
|
259
|
+
analysis does not change with whatever happens to sit in the directory.
|
|
260
|
+
Everything in [Knip's configuration reference](https://knip.dev/reference/configuration)
|
|
261
|
+
works there unchanged.
|
|
262
|
+
|
|
263
|
+
You do not have to work out what belongs there. Run the analysis and Knip
|
|
264
|
+
reports what its configuration is missing — which workspace it never reached,
|
|
265
|
+
which declared entry point resolved to nothing — under **config hints**, with
|
|
266
|
+
the file count each one accounts for:
|
|
267
|
+
|
|
268
|
+
```
|
|
269
|
+
config hints (from Knip)
|
|
270
|
+
packages/core · 12 files
|
|
271
|
+
Add entry and/or refine project files in workspaces["packages/core"] (12 unused files)
|
|
272
|
+
→ Knip settings live under `knip` in stopslop.json (knip.json is not read)
|
|
273
|
+
reference: https://knip.dev/reference/configuration
|
|
274
|
+
```
|
|
275
|
+
|
|
276
|
+
Address them, run again, repeat until they are gone. Until then dead code is
|
|
277
|
+
reported but left out of the score, because a run without entry points reports
|
|
278
|
+
live files as unreachable. The same list is in `configHints` of `--format json`.
|
|
279
|
+
|
|
255
280
|
## Node.js API
|
|
256
281
|
|
|
257
282
|
StopSlop ships ESM JavaScript and TypeScript declarations for programmatic use:
|
|
@@ -268,7 +293,8 @@ console.log(result.slop.score, result.findings);
|
|
|
268
293
|
The API also exports the resolved defaults, scoring helpers, baseline helpers,
|
|
269
294
|
and report types. See the [Node.js API guide](docs/node-api.md) for Git-base
|
|
270
295
|
analysis, typed configuration, result semantics, and custom analyzers. The API
|
|
271
|
-
is experimental
|
|
296
|
+
is experimental and may change in a minor release; see
|
|
297
|
+
[COMPATIBILITY.md](COMPATIBILITY.md).
|
|
272
298
|
|
|
273
299
|
## Design and limitations
|
|
274
300
|
|
|
@@ -277,7 +303,8 @@ is experimental before 1.0; see [COMPATIBILITY.md](COMPATIBILITY.md).
|
|
|
277
303
|
directories are excluded by default.
|
|
278
304
|
- A high score does not prove poor engineering, and a low score does not prove
|
|
279
305
|
correctness. StopSlop measures structural overproduction, not total quality.
|
|
280
|
-
- Dead-code accuracy depends on Knip knowing the project's entry points
|
|
306
|
+
- Dead-code accuracy depends on Knip knowing the project's entry points; the
|
|
307
|
+
run says so through config hints when it does not.
|
|
281
308
|
- A baseline accepts finding identities. If an accepted function becomes more
|
|
282
309
|
complex without changing identity, the score rises but the gate stays clear.
|
|
283
310
|
|
package/context7.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"description": "Static analysis and CI gate for AI code slop in JavaScript and TypeScript: cognitive complexity, god units, duplicate code, dead code, orphan features, SARIF and baselines.",
|
|
5
5
|
"folders": ["docs"],
|
|
6
6
|
"excludeFolders": [],
|
|
7
|
-
"excludeFiles": ["CHANGELOG.md", "
|
|
7
|
+
"excludeFiles": ["CHANGELOG.md", "RELEASING.md"],
|
|
8
8
|
"rules": [
|
|
9
9
|
"StopSlop detects structural code patterns; it does not determine whether code was written by a human or AI.",
|
|
10
10
|
"Run StopSlop without installing it with `npx stopslop .`. It requires Node.js ^20.19.0 or >=22.12.0 and analyzes JavaScript, JSX, TypeScript and TSX.",
|
|
@@ -16,6 +16,7 @@
|
|
|
16
16
|
"StopSlop works without configuration. Put optional overrides in `stopslop.json` and use `$schema: https://unpkg.com/stopslop/schema.json` for editor validation.",
|
|
17
17
|
"Use `--fast` only when intentionally skipping duplicate-code and dead-code analysis; it runs the AST checks for cognitive complexity and god units.",
|
|
18
18
|
"The Node API is ESM and typed: call `resolveConfig()` before `analyze()`, or call `loadConfig()` to read stopslop.json. The slop score always describes the complete analyzed repository.",
|
|
19
|
-
"Clone detection is powered by Clone Alert and dead-code analysis by Knip. Configure Knip only under the `knip` property in stopslop.json."
|
|
19
|
+
"Clone detection is powered by Clone Alert and dead-code analysis by Knip. Configure Knip only under the `knip` property in stopslop.json.",
|
|
20
|
+
"Knip settings go under `knip` in stopslop.json; a project's own knip.json or package.json#knip is never read. Do not write one up front — run the analysis and follow the `config hints` it prints, which come from Knip and name what is missing."
|
|
20
21
|
]
|
|
21
22
|
}
|
package/dist/cli.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import {
|
|
3
|
-
import { posix } from "node:path";
|
|
2
|
+
import { c as loadConfig, d as fingerprint, f as readBaseline, n as analyzeGitBase, p as writeBaseline, s as configFilePath, t as analyze, u as applyBaseline } from "./src.js";
|
|
3
|
+
import { posix, relative, sep } from "node:path";
|
|
4
4
|
import { createHash } from "node:crypto";
|
|
5
5
|
import pc from "picocolors";
|
|
6
6
|
//#region src/report/terminal.ts
|
|
@@ -69,8 +69,29 @@ const LEVEL_COLOR = {
|
|
|
69
69
|
high: pc.red,
|
|
70
70
|
"legacy-grade": pc.red
|
|
71
71
|
};
|
|
72
|
+
/**
|
|
73
|
+
* What Knip says is missing from the configuration. This block is the whole
|
|
74
|
+
* setup story: a dead-code run is only as good as its entry points, and Knip
|
|
75
|
+
* is the one that knows which of them came up empty. The last line names the
|
|
76
|
+
* file to edit — the one thing Knip cannot know, and the thing an agent
|
|
77
|
+
* otherwise guesses wrong by writing knip.json, which StopSlop never reads.
|
|
78
|
+
*/
|
|
79
|
+
function renderConfigHints(result) {
|
|
80
|
+
if (result.configHints.length === 0) return [];
|
|
81
|
+
const lines = ["", " " + pc.bold("config hints") + pc.dim(" (from Knip)")];
|
|
82
|
+
for (const hint of result.configHints) {
|
|
83
|
+
const where = hint.workspace && hint.workspace !== hint.identifier ? ` in ${hint.workspace}` : "";
|
|
84
|
+
const size = hint.size === void 0 ? "" : ` · ${hint.size} files`;
|
|
85
|
+
lines.push(` ${pc.yellow(hint.identifier)}${pc.dim(where + size)}`);
|
|
86
|
+
lines.push(" " + pc.dim(hint.message));
|
|
87
|
+
}
|
|
88
|
+
const file = relative(result.root, configFilePath(result.root, result.config)).split(sep).join("/");
|
|
89
|
+
lines.push(" " + pc.dim(`→ Knip settings live under \`knip\` in ${file} (knip.json is not read)`));
|
|
90
|
+
lines.push(" " + pc.dim(" reference: https://knip.dev/reference/configuration"));
|
|
91
|
+
return lines;
|
|
92
|
+
}
|
|
72
93
|
function renderFooter(result) {
|
|
73
|
-
const lines = [""];
|
|
94
|
+
const lines = [...renderConfigHints(result), ""];
|
|
74
95
|
for (const note of result.notes) lines.push(" " + pc.dim(note));
|
|
75
96
|
if (result.config.preliminary) lines.push(" " + pc.yellow("thresholds are preliminary (pre-calibration) — see docs/thresholds.md"));
|
|
76
97
|
if (result.errors.length > 0) lines.push(" " + pc.dim(`${result.errors.length} file(s) skipped on error`));
|
|
@@ -189,6 +210,12 @@ function toJson(result) {
|
|
|
189
210
|
summary: summarize(result),
|
|
190
211
|
findings: result.findings,
|
|
191
212
|
notes: result.notes,
|
|
213
|
+
configHints: result.configHints,
|
|
214
|
+
/** Where Knip settings are read from. Nowhere else is consulted. */
|
|
215
|
+
configFile: {
|
|
216
|
+
path: relative(result.root, configFilePath(result.root, result.config)).split(sep).join("/"),
|
|
217
|
+
property: "knip"
|
|
218
|
+
},
|
|
192
219
|
errors: result.errors
|
|
193
220
|
}, null, 2);
|
|
194
221
|
}
|
package/dist/index.d.ts
CHANGED
|
@@ -44,12 +44,35 @@ interface Analyzer {
|
|
|
44
44
|
interface AnalyzeContext {
|
|
45
45
|
config: ResolvedConfig;
|
|
46
46
|
}
|
|
47
|
+
/**
|
|
48
|
+
* What Knip reports as missing from its configuration, computed from the run it
|
|
49
|
+
* just did. Knip owns this judgement — it knows which entry pattern matched
|
|
50
|
+
* nothing and which workspace it never reached, and it counts the files that
|
|
51
|
+
* hang off each. StopSlop adds one thing Knip cannot know: where the
|
|
52
|
+
* configuration lives.
|
|
53
|
+
*/
|
|
54
|
+
interface ConfigHint {
|
|
55
|
+
/** Knip's hint type: `workspace-unconfigured`, `package-entry`, `ignore`, … */
|
|
56
|
+
type: string;
|
|
57
|
+
/** What it is about — a workspace key, a path, a dependency name. */
|
|
58
|
+
identifier: string;
|
|
59
|
+
/** Knip's own wording. */
|
|
60
|
+
message: string;
|
|
61
|
+
/** Workspace the hint belongs to — what tells two identical ones apart. */
|
|
62
|
+
workspace?: string;
|
|
63
|
+
/** File the hint is about, relative to the analyzed root. */
|
|
64
|
+
filePath?: string;
|
|
65
|
+
/** Unused files attributable to this hint, where Knip counted them. */
|
|
66
|
+
size?: number;
|
|
67
|
+
}
|
|
47
68
|
interface ProjectContext {
|
|
48
69
|
root: string;
|
|
49
70
|
files: ParsedFile[];
|
|
50
71
|
config: ResolvedConfig;
|
|
51
72
|
/** Non-fatal notes from an engine (e.g. "knip skipped: no package.json"). */
|
|
52
73
|
notes: string[];
|
|
74
|
+
/** Configuration Knip found missing. Empty when it has nothing to say. */
|
|
75
|
+
configHints: ConfigHint[];
|
|
53
76
|
/**
|
|
54
77
|
* What the Stage-2 engines actually measured. An engine that was disabled —
|
|
55
78
|
* or that bailed out at runtime — leaves its entry unset, and the score then
|
|
@@ -147,6 +170,12 @@ interface ResolvedConfig {
|
|
|
147
170
|
ignore: string[];
|
|
148
171
|
/** Whether current thresholds are provisional. False for the calibrated defaults. */
|
|
149
172
|
preliminary: boolean;
|
|
173
|
+
/**
|
|
174
|
+
* The stopslop.json `loadConfig` read — or looked for, when there is none.
|
|
175
|
+
* Unset for an in-memory `resolveConfig()`; the analyzed root's own
|
|
176
|
+
* stopslop.json stands in then.
|
|
177
|
+
*/
|
|
178
|
+
configFile?: string;
|
|
150
179
|
}
|
|
151
180
|
//#endregion
|
|
152
181
|
//#region src/score.d.ts
|
|
@@ -267,6 +296,8 @@ interface AnalyzeResult {
|
|
|
267
296
|
errors: string[];
|
|
268
297
|
/** Non-fatal notes from the Stage-2 engines (skipped checks, and why). */
|
|
269
298
|
notes: string[];
|
|
299
|
+
/** What Knip reports as missing from `stopslop.json#knip`, from this run. */
|
|
300
|
+
configHints: ConfigHint[];
|
|
270
301
|
config: ResolvedConfig;
|
|
271
302
|
elapsedMs: number;
|
|
272
303
|
/**
|
|
@@ -288,4 +319,4 @@ declare function analyze(root: string, config: ResolvedConfig, analyzers?: Analy
|
|
|
288
319
|
/** Gate the current working tree against findings present at a Git revision. */
|
|
289
320
|
declare function analyzeGitBase(root: string, baseRef: string, config: ResolvedConfig, analyzers?: Analyzer[]): Promise<AnalyzeResult>;
|
|
290
321
|
//#endregion
|
|
291
|
-
export { AnalyzeResult, type Analyzer, type BaselineRecord, DEFAULT_CONFIG, type Finding, type ParsedFile, type ResolvedConfig, type SlopLevel, type SlopScore, type StopSlopConfig, analyze, analyzeGitBase, applyBaseline, computeScore, defaultAnalyzers, fingerprint, levelFor, loadConfig, readBaseline, resolveConfig, writeBaseline };
|
|
322
|
+
export { AnalyzeResult, type Analyzer, type BaselineRecord, type ConfigHint, DEFAULT_CONFIG, type Finding, type ParsedFile, type ResolvedConfig, type SlopLevel, type SlopScore, type StopSlopConfig, analyze, analyzeGitBase, applyBaseline, computeScore, defaultAnalyzers, fingerprint, levelFor, loadConfig, readBaseline, resolveConfig, writeBaseline };
|
package/dist/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as
|
|
1
|
+
import { a as levelFor, c as loadConfig, d as fingerprint, f as readBaseline, i as computeScore, l as resolveConfig, n as analyzeGitBase, o as DEFAULT_CONFIG, p as writeBaseline, r as defaultAnalyzers, t as analyze, u as applyBaseline } from "./src.js";
|
|
2
2
|
export { DEFAULT_CONFIG, analyze, analyzeGitBase, applyBaseline, computeScore, defaultAnalyzers, fingerprint, levelFor, loadConfig, readBaseline, resolveConfig, writeBaseline };
|
package/dist/src.js
CHANGED
|
Binary file
|
package/docs/configuration.md
CHANGED
|
@@ -183,9 +183,14 @@ and never merged. Move any settings StopSlop should use into this property.
|
|
|
183
183
|
|
|
184
184
|
Workspace keys and overrides follow Knip unchanged: `.` configures the root,
|
|
185
185
|
glob keys select groups of packages, and a more specific key can override a
|
|
186
|
-
group.
|
|
187
|
-
|
|
188
|
-
|
|
186
|
+
group.
|
|
187
|
+
|
|
188
|
+
Every run lists what Knip finds missing from this configuration under **config
|
|
189
|
+
hints** (`configHints` in `--format json`): a workspace it never reached, an
|
|
190
|
+
entry pattern that matched nothing, and how many unused files each accounts
|
|
191
|
+
for. While Knip reports the project or a workspace as unconfigured, dead-code
|
|
192
|
+
findings are shown but excluded from the score — without entry points, live
|
|
193
|
+
files come back unreachable.
|
|
189
194
|
|
|
190
195
|
In a single-package project, `entry` and `project` belong directly under
|
|
191
196
|
`knip`. In a monorepo they belong under `knip.workspaces`; Knip ignores the
|
package/docs/node-api.md
CHANGED
|
@@ -26,7 +26,8 @@ console.log({
|
|
|
26
26
|
|
|
27
27
|
`findings` contains the issues that should fail the current gate. `slop` always
|
|
28
28
|
describes the complete analyzed repository. Check `errors` before trusting a
|
|
29
|
-
result; `notes` explains non-fatal skips by project-level engines
|
|
29
|
+
result; `notes` explains non-fatal skips by project-level engines, and
|
|
30
|
+
`configHints` lists what Knip reports as missing from `stopslop.json#knip`.
|
|
30
31
|
|
|
31
32
|
## Load `stopslop.json`
|
|
32
33
|
|
|
@@ -110,5 +111,5 @@ const result = await analyze(
|
|
|
110
111
|
```
|
|
111
112
|
|
|
112
113
|
Custom analyzers currently return the published `Finding` union, so use an
|
|
113
|
-
existing finding kind for integrations.
|
|
114
|
-
[compatibility policy](../COMPATIBILITY.md).
|
|
114
|
+
existing finding kind for integrations. That surface is experimental and may
|
|
115
|
+
change in a minor release; see the [compatibility policy](../COMPATIBILITY.md).
|
package/docs/score.md
CHANGED
|
@@ -46,9 +46,10 @@ Three properties are deliberate:
|
|
|
46
46
|
axis, and the other axes still matter. Without the cap, one pathological file
|
|
47
47
|
would drown out everything else.
|
|
48
48
|
- **A check that did not run leaves the formula.** If you turn off `deadCode` — or
|
|
49
|
-
if Knip bails out because the project's dependencies are not installed, or
|
|
50
|
-
|
|
51
|
-
|
|
49
|
+
if Knip bails out because the project's dependencies are not installed, or
|
|
50
|
+
Knip reports the run as unconfigured (its `top-level-unconfigured` or
|
|
51
|
+
`workspace-unconfigured` config hint: more files unreachable than anything but
|
|
52
|
+
missing entry points explains) — its weight drops out of the
|
|
52
53
|
denominator instead of contributing zero. Not measuring something must never
|
|
53
54
|
read as a clean bill of health. The terminal report shows only the signals
|
|
54
55
|
that were actually measured, and says in a note why one is missing.
|
package/llms.txt
CHANGED
|
@@ -4,6 +4,8 @@
|
|
|
4
4
|
|
|
5
5
|
Run without installing: `npx stopslop .`. Exit codes are `0` for a clear gate, `1` for detected findings, and `2` for an analysis error. Requires Node.js 20.19+ or 22.12+.
|
|
6
6
|
|
|
7
|
+
Dead-code settings live under `knip` in `stopslop.json` — a project's own `knip.json` or `package.json#knip` is never read. Nothing needs to be written up front: the run prints `config hints` from Knip naming the workspace or entry point that is missing, and dead code stays out of the score until they are resolved.
|
|
8
|
+
|
|
7
9
|
## Start here
|
|
8
10
|
|
|
9
11
|
- [Overview, installation, CLI and badge](https://raw.githubusercontent.com/BaryshevRS/stopslop/main/README.md)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "stopslop",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.1.0",
|
|
4
4
|
"description": "Static analysis for AI-generated JavaScript and TypeScript: find cognitive complexity, god classes/modules, duplicate code, dead code and orphan features.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
},
|
|
68
68
|
"dependencies": {
|
|
69
69
|
"clone-alert": "^1.1.3",
|
|
70
|
-
"knip": "6.
|
|
70
|
+
"knip": "6.39.0",
|
|
71
71
|
"oxc-parser": "^0.139.0",
|
|
72
72
|
"picocolors": "^1.1.1"
|
|
73
73
|
},
|
package/schema.json
CHANGED
|
@@ -343,6 +343,9 @@
|
|
|
343
343
|
"ignoreBinaries": {
|
|
344
344
|
"$ref": "#/definitions/knip/definitions/ignoreBinaries"
|
|
345
345
|
},
|
|
346
|
+
"ignoreGlobalBinaries": {
|
|
347
|
+
"$ref": "#/definitions/knip/definitions/ignoreGlobalBinaries"
|
|
348
|
+
},
|
|
346
349
|
"ignoreDependencies": {
|
|
347
350
|
"$ref": "#/definitions/knip/definitions/ignoreDependencies"
|
|
348
351
|
},
|
|
@@ -513,6 +516,21 @@
|
|
|
513
516
|
}
|
|
514
517
|
}
|
|
515
518
|
},
|
|
519
|
+
"preprocessor": {
|
|
520
|
+
"title": "Preprocess the results before providing them to the reporter(s)",
|
|
521
|
+
"oneOf": [
|
|
522
|
+
{
|
|
523
|
+
"type": "string"
|
|
524
|
+
},
|
|
525
|
+
{
|
|
526
|
+
"$ref": "#/definitions/knip/definitions/list"
|
|
527
|
+
}
|
|
528
|
+
]
|
|
529
|
+
},
|
|
530
|
+
"preprocessorOptions": {
|
|
531
|
+
"title": "Extra options to pass to the preprocessor",
|
|
532
|
+
"type": "object"
|
|
533
|
+
},
|
|
516
534
|
"treatConfigHintsAsErrors": {
|
|
517
535
|
"title": "Exit with non-zero code (1) if there are any configuration hints",
|
|
518
536
|
"type": "boolean"
|
|
@@ -539,6 +557,12 @@
|
|
|
539
557
|
],
|
|
540
558
|
"$ref": "#/definitions/knip/definitions/list"
|
|
541
559
|
},
|
|
560
|
+
"ignoreGlobalBinaries": {
|
|
561
|
+
"title": "Ignore common global binaries",
|
|
562
|
+
"description": "Set to false to report required binaries otherwise excluded by Knip's default list. Explicit ignoreBinaries entries still apply.",
|
|
563
|
+
"type": "boolean",
|
|
564
|
+
"default": true
|
|
565
|
+
},
|
|
542
566
|
"ignoreDependencies": {
|
|
543
567
|
"title": "Dependencies to exclude from the report (regex allowed)",
|
|
544
568
|
"examples": [
|
|
@@ -710,6 +734,9 @@
|
|
|
710
734
|
"ignoreBinaries": {
|
|
711
735
|
"$ref": "#/definitions/knip/definitions/ignoreBinaries"
|
|
712
736
|
},
|
|
737
|
+
"ignoreGlobalBinaries": {
|
|
738
|
+
"$ref": "#/definitions/knip/definitions/ignoreGlobalBinaries"
|
|
739
|
+
},
|
|
713
740
|
"ignoreDependencies": {
|
|
714
741
|
"$ref": "#/definitions/knip/definitions/ignoreDependencies"
|
|
715
742
|
},
|
|
@@ -811,6 +838,10 @@
|
|
|
811
838
|
"title": "biome plugin configuration (https://knip.dev/reference/plugins/biome)",
|
|
812
839
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
813
840
|
},
|
|
841
|
+
"borp": {
|
|
842
|
+
"title": "borp plugin configuration (https://knip.dev/reference/plugins/borp)",
|
|
843
|
+
"$ref": "#/definitions/knip/definitions/plugin"
|
|
844
|
+
},
|
|
814
845
|
"bumpp": {
|
|
815
846
|
"title": "bumpp plugin configuration (https://knip.dev/reference/plugins/bumpp)",
|
|
816
847
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
@@ -1027,6 +1058,10 @@
|
|
|
1027
1058
|
"title": "metro plugin configuration (https://knip.dev/reference/plugins/metro)",
|
|
1028
1059
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
1029
1060
|
},
|
|
1061
|
+
"mise": {
|
|
1062
|
+
"title": "mise plugin configuration (https://knip.dev/reference/plugins/mise)",
|
|
1063
|
+
"$ref": "#/definitions/knip/definitions/plugin"
|
|
1064
|
+
},
|
|
1030
1065
|
"mocha": {
|
|
1031
1066
|
"title": "Mocha plugin configuration (https://knip.dev/reference/plugins/mocha)",
|
|
1032
1067
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
@@ -1167,6 +1202,10 @@
|
|
|
1167
1202
|
"title": "PostCSS plugin configuration (https://knip.dev/reference/plugins/postcss)",
|
|
1168
1203
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
1169
1204
|
},
|
|
1205
|
+
"pre-commit": {
|
|
1206
|
+
"title": "pre-commit plugin configuration (https://knip.dev/reference/plugins/pre-commit)",
|
|
1207
|
+
"$ref": "#/definitions/knip/definitions/plugin"
|
|
1208
|
+
},
|
|
1170
1209
|
"preconstruct": {
|
|
1171
1210
|
"title": "preconstruct plugin configuration (https://knip.dev/reference/plugins/preconstruct)",
|
|
1172
1211
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
@@ -1187,6 +1226,10 @@
|
|
|
1187
1226
|
"title": "qwik plugin configuration (https://knip.dev/reference/plugins/qwik)",
|
|
1188
1227
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
1189
1228
|
},
|
|
1229
|
+
"railway": {
|
|
1230
|
+
"title": "railway plugin configuration (https://knip.dev/reference/plugins/railway)",
|
|
1231
|
+
"$ref": "#/definitions/knip/definitions/plugin"
|
|
1232
|
+
},
|
|
1190
1233
|
"react-cosmos": {
|
|
1191
1234
|
"title": "react-cosmos plugin configuration (https://knip.dev/reference/plugins/react-cosmos)",
|
|
1192
1235
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
@@ -1339,6 +1382,10 @@
|
|
|
1339
1382
|
"title": "temporal plugin configuration (https://knip.dev/reference/plugins/temporal)",
|
|
1340
1383
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
1341
1384
|
},
|
|
1385
|
+
"textlint": {
|
|
1386
|
+
"title": "textlint plugin configuration (https://knip.dev/reference/plugins/textlint)",
|
|
1387
|
+
"$ref": "#/definitions/knip/definitions/plugin"
|
|
1388
|
+
},
|
|
1342
1389
|
"travis": {
|
|
1343
1390
|
"title": "travis plugin configuration (https://knip.dev/reference/plugins/travis)",
|
|
1344
1391
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
@@ -1347,6 +1394,10 @@
|
|
|
1347
1394
|
"title": "ts-node plugin configuration (https://knip.dev/reference/plugins/ts-node)",
|
|
1348
1395
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
1349
1396
|
},
|
|
1397
|
+
"tsd": {
|
|
1398
|
+
"title": "tsd plugin configuration (https://knip.dev/reference/plugins/tsd)",
|
|
1399
|
+
"$ref": "#/definitions/knip/definitions/plugin"
|
|
1400
|
+
},
|
|
1350
1401
|
"tsdown": {
|
|
1351
1402
|
"title": "tsdown plugin configuration (https://knip.dev/reference/plugins/tsdown)",
|
|
1352
1403
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
@@ -1359,6 +1410,10 @@
|
|
|
1359
1410
|
"title": "tsx plugin configuration (https://knip.dev/reference/plugins/tsx)",
|
|
1360
1411
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
1361
1412
|
},
|
|
1413
|
+
"turbo": {
|
|
1414
|
+
"title": "turbo plugin configuration (https://knip.dev/reference/plugins/turbo)",
|
|
1415
|
+
"$ref": "#/definitions/knip/definitions/plugin"
|
|
1416
|
+
},
|
|
1362
1417
|
"typedoc": {
|
|
1363
1418
|
"title": "typedoc plugin configuration (https://knip.dev/reference/plugins/typedoc)",
|
|
1364
1419
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
@@ -1367,6 +1422,10 @@
|
|
|
1367
1422
|
"title": "TypeScript plugin configuration (https://knip.dev/reference/plugins/typescript)",
|
|
1368
1423
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
1369
1424
|
},
|
|
1425
|
+
"typescript-content-mapper": {
|
|
1426
|
+
"title": "typescript-content-mapper plugin configuration (https://knip.dev/reference/plugins/typescript-content-mapper)",
|
|
1427
|
+
"$ref": "#/definitions/knip/definitions/plugin"
|
|
1428
|
+
},
|
|
1370
1429
|
"unbuild": {
|
|
1371
1430
|
"title": "unbuild plugin configuration (https://knip.dev/reference/plugins/unbuild)",
|
|
1372
1431
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
@@ -1399,6 +1458,10 @@
|
|
|
1399
1458
|
"title": "unplugin-vue-router plugin configuration (https://knip.dev/reference/plugins/unplugin-vue-router)",
|
|
1400
1459
|
"$ref": "#/definitions/knip/definitions/plugin"
|
|
1401
1460
|
},
|
|
1461
|
+
"varlock": {
|
|
1462
|
+
"title": "varlock plugin configuration (https://knip.dev/reference/plugins/varlock)",
|
|
1463
|
+
"$ref": "#/definitions/knip/definitions/plugin"
|
|
1464
|
+
},
|
|
1402
1465
|
"vercel": {
|
|
1403
1466
|
"title": "vercel plugin configuration (https://knip.dev/reference/plugins/vercel)",
|
|
1404
1467
|
"$ref": "#/definitions/knip/definitions/plugin"
|