-
-
Notifications
You must be signed in to change notification settings - Fork 721
Open
Labels
A-linterArea - LinterArea - Linter
Description
Trying to keep some projects clean by not allowing inline disables in favour of proper configuration of fitting rules for the project. I'm liking it in my ESLint config and would like to apply it to Oxlint as well before migrating.
In ESLint the following configuration can be used to not allow inline comments:
{
linterOptions: {
noInlineConfig: true, // ignores all /* eslint-disable */ etc.
reportUnusedDisableDirectives: 'error',
},
}For Oxlint the best we have (that I could find) is
We also have
# report unused rules as warnings
oxlint --report-unused-disable-directives
# report unused as errors
oxlint --report-unused-disable-directives-severity=errorBut there is currently no way to disallow inline config completely for a project.
It would be really nice if we could have noInlineConfig setting or rule for Oxlint.
Considered alternatives
We could probably do this with a custom rule
Metadata
Metadata
Assignees
Labels
A-linterArea - LinterArea - Linter