Oxlint ".oxlintrc.json" Config / Unknown Rule Errors - Fix in CI
Oxlint is a fast Rust linter configured via .oxlintrc.json. It errors out - rather than just reporting lint findings - when the config is malformed, references an unknown rule or category, or enables a plugin namespace it does not recognize.
What this error means
Running oxlint (or npx oxlint) exits with a configuration error: Failed to parse configuration, an unknown-rule message, or an invalid category/plugin name. It reproduces every run against that config.
! Failed to parse configuration file .oxlintrc.json
unknown rule "no-consol" in "rules"
# or:
unknown plugin "typescirpt" in "plugins"Common causes
Malformed or mistyped config
Invalid JSON, a misspelled rule name (no-consol), or an unknown category in .oxlintrc.json makes oxlint reject the configuration before linting.
Plugin not enabled or misnamed
A rule belongs to a plugin namespace (e.g. typescript, react, import) that is not listed in plugins, or the plugin name is mistyped, so oxlint cannot apply it.
How to fix it
Write a valid .oxlintrc.json
Use strict JSON, real rule names, and enable the plugins your rules need.
// .oxlintrc.json
{
"plugins": ["typescript", "react", "import"],
"categories": { "correctness": "error" },
"rules": { "no-console": "warn" }
}Validate the config and rule names
- Confirm
.oxlintrc.jsonis strict JSON (no comments/trailing commas). - Check each rule name against the oxlint rules reference.
- Enable the plugin namespace for any plugin-scoped rule you use.
How to prevent it
- Keep
.oxlintrc.jsonas strict JSON and validate it in CI. - Enable the plugin for every plugin-scoped rule.
- Verify rule names against the oxlint reference before adding them.