Make no-unused-components linting rule configurable to apply only to specific components
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 1.5k
- Forks
- 228
- Avg merge
- 1d 14h
- Merged PRs (30d)
- 48
Description
As your docs suggest:
However, your API document may contain common components used in other APIs. If that describes your use-case, turn this rule off.
...there may be components defined which are used in other APIs. It would thus be beneficial to make this rule specific to some components only, but the only configuration option I can see is to either turn it off entirely or not.
Maybe adding some of your already configurable rule keys like matchParentKeys could solve this issue by referring to the NamedSchema type and specifing an according anti-regex pattern (that matches all except the ones in relation to which the rules should not be applied).
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the no-unused-components rule documentation and its current all-or-nothing configuration, then read the configurable-rules guidance for matchParentKeys and the NamedSchema subject. Done means the rule can be limited to selected components while retaining an option to disable it entirely, with the behavior documented.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- openapi, typescript
- Domain
- api, tooling
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100