diff --git a/apps/oxlint/src/command/lint.rs b/apps/oxlint/src/command/lint.rs index c82612955e24d..ef96730f67360 100644 --- a/apps/oxlint/src/command/lint.rs +++ b/apps/oxlint/src/command/lint.rs @@ -127,7 +127,11 @@ pub struct BasicOptions { /// Oxlint automatically discovers the relevant `tsconfig.json` for each file. /// Use this only when your project uses a non-standard tsconfig name or location. /// - /// NOTE: Type checking and Type aware rules will still use the tsconfig discovered automatically, and will not be affected by this option. + /// ::: warning + /// Avoid using this this option. It can cause differences between import resolution, + /// and type-aware linting. Type aware linting **does not** respect this option, + /// and will always discover the appropriate `tsconfig.json` for each file automatically. + /// ::: #[bpaf(argument("./tsconfig.json"), hide_usage)] pub tsconfig: Option, diff --git a/tasks/website_linter/src/snapshots/cli.snap b/tasks/website_linter/src/snapshots/cli.snap index 21ca2dc97c293..174c40cafac62 100644 --- a/tasks/website_linter/src/snapshots/cli.snap +++ b/tasks/website_linter/src/snapshots/cli.snap @@ -22,7 +22,7 @@ search: false - **` --tsconfig`**=_`<./tsconfig.json>`_ — Override the TypeScript config used for import resolution. Oxlint automatically discovers the relevant `tsconfig.json` for each file. Use this only when your project uses a non-standard tsconfig name or location. - NOTE: Type checking and Type aware rules will still use the tsconfig discovered automatically, and will not be affected by this option. + ::: warning Avoid using this this option. It can cause differences between import resolution, and type-aware linting. Type aware linting **does not** respect this option, and will always discover the appropriate `tsconfig.json` for each file automatically. ::: - **` --init`** — Initialize oxlint configuration with default values