Skip to content

Commit

Permalink
Add includeEntryExports to workspace config in TS and JSON schema
Browse files Browse the repository at this point in the history
  • Loading branch information
webpro committed Nov 29, 2023
1 parent ec64c07 commit 1a848d9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/knip/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@
]
},
"includeEntryExports": {
"title": "Include entry files when reporting unused exports",
"type": "boolean"
},
"workspaces": {
Expand Down Expand Up @@ -187,6 +188,10 @@
"title": "Dependencies from package.json to ignore",
"examples": ["husky", "lint-staged"],
"$ref": "#/definitions/list"
},
"includeEntryExports": {
"title": "Include entry files when reporting unused exports",
"type": "boolean"
}
}
},
Expand Down
1 change: 1 addition & 0 deletions packages/knip/src/ConfigurationValidator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ const baseWorkspaceConfigurationSchema = z.object({
ignore: globSchema.optional(),
ignoreBinaries: z.array(z.string()).optional(),
ignoreDependencies: z.array(z.string()).optional(),
includeEntryExports: z.boolean().optional(),
});

const workspaceConfigurationSchema = baseWorkspaceConfigurationSchema.merge(pluginsSchema.partial());
Expand Down

0 comments on commit 1a848d9

Please sign in to comment.