Skip to content

Commit 31bd575

Browse files
ryanbas21claude
andcommitted
chore: add changeset for eslint-plugin-treeshake
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 9d83665 commit 31bd575

1 file changed

Lines changed: 18 additions & 0 deletions

File tree

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
'@wolfcola/eslint-plugin-treeshake': minor
3+
---
4+
5+
Add @wolfcola/eslint-plugin-treeshake - an ESLint plugin that flags code patterns known to break tree-shaking.
6+
7+
Implements a single rule `wolfcola/no-treeshake-hazard` with static checks for:
8+
9+
- TypeScript enums (with `as const` suggestion)
10+
- Unannotated top-level calls (with `/*#__PURE__*/` autofix)
11+
- Prototype/property mutations at module scope
12+
- Global object assignments
13+
- CommonJS patterns in ESM files
14+
- Missing `sideEffects` field in package.json
15+
16+
Includes opt-in `bundleCheck` mode that runs `@wolfcola/treeshake-check`'s full Rollup analysis and maps results back to source locations, with deduplication against static findings.
17+
18+
Ships with `recommended` (warn) and `strict` (error + bundleCheck) preset configs.

0 commit comments

Comments
 (0)