Skip to content

linter: enabling import plugin in override causes no-unused-vars violations to be reported as warnings #21472

Description

@rtarpine-vanta

What version of Oxlint are you using?

1.60.0

What command did you run?

oxlint testfile.ts

What does your .oxlintrc.json (or oxlint.config.ts) config file look like?

{
  "$schema": "./node_modules/oxlint/configuration_schema.json",
  "categories": {
    "correctness": "off",
  },
  "rules": {},
  "overrides": [
    {
      "files": ["**/*.ts"],
      "plugins": ["import"],
    },
  ],
}

What happened?

If I run oxlint with that config on this file:

const answer = 42;

then it warns eslint(no-unused-vars): Variable 'answer' is declared but never used. I didn't expect that since I thought all rules are disabled.

If I remove the "plugins": ["import"], line, then (as expected) no warnings or errors are reported.

I don't get any warning if I set "plugins": ["import"] at the top-level (outside of overrides), nor if I use a different plugin like "unicorn" in the override.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Fields

    Priority

    None yet

    Effort

    None yet

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions