Consider the following config:
export default {
ignoreFiles: [ "eslint.config.mjs" ],
};
This config is subtly bugged because "ignoreFiles" should really be called "ignore". However, instead of sensibly throwing an error with something along the lines of Error: The "ignoreFiles" configuration field is unknown.
, Knip will instead silently ignore it and then charge ahead as per normal, complaining about "eslint.config.mjs" being unused.
One possible solution here is to show bugged config entries as "hints", and that would have the advantage of not breaking lint runs for users who have existing bugged/invalid configs.
However, I would strongly recommend to throw a hard error instead of a hint, as hints can be hidden from people for a really long time. Related issue: #891
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too