react-doctor 0.8.1 → 0.8.2-dev.8d4d5a8
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/README.md +0 -8
- package/dist/{chunk-N93fKeF6.js → chunk-ChKA3wi6.js} +5 -4
- package/dist/cli.js +31049 -464
- package/dist/index.d.ts +54 -15
- package/dist/index.js +30274 -158
- package/dist/lsp.js +30275 -158
- package/dist/skills/improve-react/AUDIT.md +1 -1
- package/dist/skills/react-doctor/SKILL.md +5 -0
- package/package.json +6 -6
package/dist/index.d.ts
CHANGED
|
@@ -9030,11 +9030,12 @@ interface Diagnostic {
|
|
|
9030
9030
|
* Set when the finding's identity is the flagged element itself (a missing
|
|
9031
9031
|
* attribute, a wrong element) rather than the flagged line's text — every
|
|
9032
9032
|
* Accessibility-category finding, plus rules that opt in via their
|
|
9033
|
-
* `matchByOccurrence` metadata flag.
|
|
9034
|
-
* by `(
|
|
9035
|
-
*
|
|
9036
|
-
*
|
|
9037
|
-
*
|
|
9033
|
+
* `matchByOccurrence` metadata flag. After strict evidence matching,
|
|
9034
|
+
* `computeDiagnosticDelta` may match these by same-file `(plugin/rule,
|
|
9035
|
+
* message)` occurrence count, so reformatting the flagged element doesn't
|
|
9036
|
+
* reclassify a pre-existing finding as new. Resolved at diagnostic creation,
|
|
9037
|
+
* where rule metadata is available. Absent means diagnosed-source-sensitive
|
|
9038
|
+
* matching (the default).
|
|
9038
9039
|
*/
|
|
9039
9040
|
matchByOccurrence?: boolean;
|
|
9040
9041
|
/**
|
|
@@ -9542,11 +9543,52 @@ interface ProjectInfo {
|
|
|
9542
9543
|
zodVersion: string | null;
|
|
9543
9544
|
/** Parsed major from `zodVersion`, or `null` when absent/unparseable. Mirrors `reactMajorVersion`. */
|
|
9544
9545
|
zodMajorVersion: number | null;
|
|
9546
|
+
/** Declared MobX core version spec. Optional so existing `ProjectInfo` consumers remain source-compatible. */
|
|
9547
|
+
mobxVersion?: string | null;
|
|
9548
|
+
/** Parsed major from `mobxVersion`, or `null` when absent/unparseable. */
|
|
9549
|
+
mobxMajorVersion?: number | null;
|
|
9550
|
+
hasMobxReact?: boolean;
|
|
9551
|
+
mobxReactVersion?: string | null;
|
|
9552
|
+
hasMobxReactLite?: boolean;
|
|
9553
|
+
mobxReactLiteVersion?: string | null;
|
|
9554
|
+
hasMobxStateTree?: boolean;
|
|
9555
|
+
hasMobxReactObserver?: boolean;
|
|
9556
|
+
/** Declared Zustand version spec. Optional so existing `ProjectInfo` consumers remain source-compatible. */
|
|
9557
|
+
zustandVersion?: string | null;
|
|
9558
|
+
/** Parsed major from `zustandVersion`, or `null` when absent/unparseable. */
|
|
9559
|
+
zustandMajorVersion?: number | null;
|
|
9545
9560
|
framework: Framework;
|
|
9546
9561
|
hasTypeScript: boolean;
|
|
9547
9562
|
hasReactCompiler: boolean;
|
|
9548
9563
|
hasReactCompilerLintPlugin?: boolean;
|
|
9549
9564
|
hasTanStackQuery: boolean;
|
|
9565
|
+
hasRemotion?: boolean;
|
|
9566
|
+
remotionVersion?: string | null;
|
|
9567
|
+
remotionMajorVersion?: number | null;
|
|
9568
|
+
hasI18nLibrary?: boolean;
|
|
9569
|
+
tanstackQueryVersion?: string | null;
|
|
9570
|
+
styledComponentsVersion?: string | null;
|
|
9571
|
+
/** Whether the project or one of its workspaces declares Three.js, Fiber, or Drei. */
|
|
9572
|
+
hasThree?: boolean;
|
|
9573
|
+
/** Lowest declared Three.js version across the project and its workspaces. */
|
|
9574
|
+
threeVersion?: string | null;
|
|
9575
|
+
/** Three.js release number parsed from threeVersion (`0.146.x` becomes 146). */
|
|
9576
|
+
threeRelease?: number | null;
|
|
9577
|
+
/** Whether the project or one of its workspaces declares React Three Fiber or Drei. */
|
|
9578
|
+
hasReactThreeFiber?: boolean;
|
|
9579
|
+
/** Declared version of @react-three/fiber or its legacy package name, when directly present. */
|
|
9580
|
+
reactThreeFiberVersion?: string | null;
|
|
9581
|
+
/** Parsed major from reactThreeFiberVersion, or null when absent or unparseable. */
|
|
9582
|
+
reactThreeFiberMajorVersion?: number | null;
|
|
9583
|
+
/**
|
|
9584
|
+
* The declared `valtio` version spec, or `null` when no package in the
|
|
9585
|
+
* analyzed project declares Valtio. `useSnapshot` has kept the same
|
|
9586
|
+
* render-read contract across Valtio 1 and 2, so presence alone drives the
|
|
9587
|
+
* `valtio` capability and its parsed major-version ladder.
|
|
9588
|
+
*/
|
|
9589
|
+
valtioVersion: string | null;
|
|
9590
|
+
/** Parsed major from `valtioVersion`, or `null` when absent/unparseable. */
|
|
9591
|
+
valtioMajorVersion: number | null;
|
|
9550
9592
|
/**
|
|
9551
9593
|
* `true` when the project or a workspace declares a Vite-based SSR runtime
|
|
9552
9594
|
* such as React Router's Node adapter, Vike, or vite-plugin-ssr.
|
|
@@ -9580,6 +9622,10 @@ interface ProjectInfo {
|
|
|
9580
9622
|
hasReactNativeWorkspace: boolean;
|
|
9581
9623
|
nextjsVersion: string | null;
|
|
9582
9624
|
nextjsMajorVersion: number | null;
|
|
9625
|
+
/** Declared React Router runtime version from `@react-router/dev`, `react-router-dom`, or `react-router`. */
|
|
9626
|
+
reactRouterVersion?: string | null;
|
|
9627
|
+
/** Whether the project declares `@react-router/dev` and therefore uses Framework mode. */
|
|
9628
|
+
hasReactRouterFramework?: boolean;
|
|
9583
9629
|
/**
|
|
9584
9630
|
* The declared `expo` package version spec (e.g. `"~51.0.0"`), looked up
|
|
9585
9631
|
* in the project or any of its workspace packages, or `null` when `expo`
|
|
@@ -9847,7 +9893,8 @@ interface InspectResult {
|
|
|
9847
9893
|
baselineDelta?: {
|
|
9848
9894
|
/** The commit the base content was read from (resolved merge-base). */baseRef: string; /** Findings present at base but gone at head — resolved by the change. */
|
|
9849
9895
|
fixedCount: number; /** Total findings at base (over the same files), for context. */
|
|
9850
|
-
baseTotalCount: number;
|
|
9896
|
+
baseTotalCount: number; /** Pre-existing findings matched after moving to a different file. */
|
|
9897
|
+
crossFileMatchCount?: number;
|
|
9851
9898
|
};
|
|
9852
9899
|
}
|
|
9853
9900
|
/**
|
|
@@ -10263,15 +10310,7 @@ declare const buildJsonReport: (input: BuildJsonReportInput) => JsonReportV3$1;
|
|
|
10263
10310
|
* `GitBaseBranchMissing`) as clean user errors instead of crashes.
|
|
10264
10311
|
*/
|
|
10265
10312
|
declare const getDiffInfo: (directory: string, explicitBaseBranch?: string, includeUntracked?: boolean) => Promise<DiffInfo | null>;
|
|
10266
|
-
declare const filterSourceFiles: (filePaths: string
|
|
10267
|
-
/**
|
|
10268
|
-
* Programmatic façade over `Git.changedLineRanges` (the `lines` scope). Diffs
|
|
10269
|
-
* `files` with `--unified=0` against `baseRef` (or the index when `cached`),
|
|
10270
|
-
* returning per-file changed line ranges relative to `directory`. Returns
|
|
10271
|
-
* `null` when the ranges can't be computed (git unavailable / unsafe ref /
|
|
10272
|
-
* non-zero exit) so the caller degrades to file-level scope; an empty array
|
|
10273
|
-
* means git succeeded but the files added no lines.
|
|
10274
|
-
*/
|
|
10313
|
+
declare const filterSourceFiles: (filePaths: ReadonlyArray<string>) => string[];
|
|
10275
10314
|
//#endregion
|
|
10276
10315
|
//#region src/summarize-diagnostics.d.ts
|
|
10277
10316
|
declare const summarizeDiagnostics: (diagnostics: Diagnostic[], worstScore?: number | null, worstScoreLabel?: string | null) => JsonReportSummary; //#endregion
|