feat: Add exclude as a complement to exclude.
PR Checklist
Please check if your PR fulfills the following requirements:
- [x] The commit message follows our guidelines: https://github.com/nestjs/nest/blob/master/CONTRIBUTING.md
- [x] Tests for the changes have been added (for bug fixes / features)
- [x] Docs have been added / updated (for bug fixes / features)
PR Type
What kind of change does this PR introduce?
[ ] Bugfix
[x] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] CI related changes
[ ] Other... Please describe:
What is the current behavior?
https://github.com/nestjs/swagger/issues/1288
Issue Number: 1288
What is the new behavior?
exclude works as a complement to include.
Does this PR introduce a breaking change?
[ ] Yes
[x] No
Other information
@evantrimboli I would grateful if you would resolve conflicts to push it further. I also need this feature :slightly_smiling_face:
The code here looks solid. If we can get the conflicts resolved I could see this being useful.
Upon reflection I think this PR doesn't make sense as-is. I think it would be better to alter the type of include to:
type IncludeFn = (module: Function) => boolean;
include?: IncludeFn | Function[];
Upon reflection I think this PR doesn't make sense as-is. I think it would be better to alter the type of include to:
type IncludeFn = (module: Function) => boolean; include?: IncludeFn | Function[];
Oh, even better with less complexity. I'm game for that
Was this included on another PR or it was abandoned?