forked from matrix-org/matrix-js-sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add knip unused code & dependency analyser (matrix-org#4013)
- Loading branch information
Showing
5 changed files
with
957 additions
and
129 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
import { KnipConfig } from "knip"; | ||
|
||
export default { | ||
entry: [ | ||
"src/index.ts", | ||
"src/types.ts", | ||
"src/browser-index.ts", | ||
"src/indexeddb-worker.ts", | ||
"scripts/**", | ||
"spec/**", | ||
"release.sh", | ||
// For now, we include all source files as entrypoints as we have been bad about gutwrenched imports | ||
"src/**", | ||
], | ||
project: ["**/*.{js,ts}"], | ||
ignore: ["examples/**"], | ||
ignoreDependencies: [ | ||
// Required for `action-validator` | ||
"@action-validator/*", | ||
// Used for git pre-commit hooks | ||
"husky", | ||
// Used in script which only runs in environment with `@octokit/rest` installed | ||
"@octokit/rest", | ||
// Used by jest | ||
"jest-environment-jsdom", | ||
"babel-jest", | ||
"ts-node", | ||
// Used by `@babel/plugin-transform-runtime` | ||
"@babel/runtime", | ||
], | ||
ignoreBinaries: [ | ||
// Used when available by reusable workflow `.github/workflows/release-make.yml` | ||
"dist", | ||
], | ||
ignoreExportsUsedInFile: true, | ||
} satisfies KnipConfig; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.