Skip to content

chore: enable exactOptionalPropertyTypes, noFallthroughCasesInSwitch, noImplicitOverride#95

Merged
zeevdr merged 2 commits into
mainfrom
tighten-tsconfig-strictness
May 25, 2026
Merged

chore: enable exactOptionalPropertyTypes, noFallthroughCasesInSwitch, noImplicitOverride#95
zeevdr merged 2 commits into
mainfrom
tighten-tsconfig-strictness

Conversation

@zeevdr
Copy link
Copy Markdown
Member

@zeevdr zeevdr commented May 25, 2026

Summary

  • Enables three stricter TypeScript compiler checks before 1.0 to catch a class of bugs at compile time rather than runtime.
  • exactOptionalPropertyTypes required a targeted fix in DecreeError to guard the optional code property assignment.
  • noImplicitOverride required adding override to ConfigWatcher's on, once, and emit overloads that shadow EventEmitter methods.

Test plan

  • npx tsc --noEmit passes with no errors
  • All 222 unit tests pass
  • Biome lint and format pass

Closes #63

… noImplicitOverride

Enable three stricter tsconfig flags before 1.0:
- exactOptionalPropertyTypes: guard the optional `code` assignment in
  DecreeError constructor to avoid writing `undefined` to an optional
  property
- noFallthroughCasesInSwitch: no source changes needed
- noImplicitOverride: add `override` modifier to ConfigWatcher.on,
  once, and emit overloads that shadow EventEmitter methods

Co-Authored-By: Claude <noreply@anthropic.com>
Closes #63
@zeevdr zeevdr added this to the Beta Readiness milestone May 25, 2026
@zeevdr zeevdr added size: S Quick win — a few hours or less priority: P2 Nice-to-have labels May 25, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented May 25, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@zeevdr zeevdr enabled auto-merge (squash) May 25, 2026 15:37
@zeevdr zeevdr merged commit 8d8e4c2 into main May 25, 2026
13 checks passed
@zeevdr zeevdr deleted the tighten-tsconfig-strictness branch May 25, 2026 15:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

priority: P2 Nice-to-have size: S Quick win — a few hours or less

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Tighten tsconfig strictness: exactOptionalPropertyTypes, noFallthroughCasesInSwitch, noImplicitOverride

1 participant