feat: Add scanning for dead code with knip (#35072)

* Add knip as dev dependency.

* Add config and script for knip.

* Add additional ignores to the file list.

* Remove knip as a dependency, download and run it :).
This commit is contained in:
Ivan Vasilov
2025-04-16 17:07:35 +02:00
committed by GitHub
parent 08e5abc64a
commit d39671f1c9
3 changed files with 18 additions and 9 deletions

15
knip.jsonc Normal file
View File

@@ -0,0 +1,15 @@
{
"$schema": "https://unpkg.com/knip@5/schema-jsonc.json",
"exclude": ["types", "exports"],
"ignore": [
"examples/**",
"**/*.mdx",
// skip supabase functions
"supabase/functions/**",
"**/*.test.ts",
// ignore studio public folder
"apps/studio/public/**",
// ignore studio components, they're dynamically imported
"apps/studio/components/interfaces/Connect/content/**",
],
}