Skip to content

Required all TypeScript syntax to be erasable in parse-email-address#26697

Merged
EvanHahn merged 1 commit intomainfrom
parse-email-address-enable-erasablesyntaxonly-tsconfig
Mar 4, 2026
Merged

Required all TypeScript syntax to be erasable in parse-email-address#26697
EvanHahn merged 1 commit intomainfrom
parse-email-address-enable-erasablesyntaxonly-tsconfig

Conversation

@EvanHahn
Copy link
Copy Markdown
Contributor

@EvanHahn EvanHahn commented Mar 4, 2026

no ref

Node can natively run TypeScript files, but only if they have "erasable syntax". This means it can't handle things like enums and namespaces.

This enforces that in the @tryghost/parse-email-address package.


Note

Low Risk
Build-time TypeScript configuration change only; main risk is new compilation errors if the package uses non-erasable TS constructs (e.g., enums/namespaces).

Overview
Adds "erasableSyntaxOnly": true to ghost/parse-email-address/tsconfig.json, enforcing that the package’s TypeScript uses only syntax Node can erase when running TS natively.

This tightens the compiler constraints and will cause the build to fail if @tryghost/parse-email-address introduces non-erasable constructs (e.g., enum, namespace) going forward.

Written by Cursor Bugbot for commit 841bb6a. This will update automatically on new commits. Configure here.

no ref

Node can natively run TypeScript files, but only if they have "erasable
syntax". This means it can't handle things like enums and namespaces.

This enforces that in the `@tryghost/parse-email-address` package.
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Mar 4, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: a77dd984-8411-49bd-ab5b-ed9c665fbd61

📥 Commits

Reviewing files that changed from the base of the PR and between 68f0990 and 841bb6a.

📒 Files selected for processing (1)
  • ghost/parse-email-address/tsconfig.json

Walkthrough

A new TypeScript compiler option erasableSyntaxOnly set to true was added to the Type Checking section of tsconfig.json in the ghost/parse-email-address package. This single-line addition modifies the TypeScript compilation configuration for the project, affecting how the compiler handles syntax-related type checking constraints during compilation.

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately describes the main change: adding erasableSyntaxOnly constraint to the parse-email-address package's TypeScript configuration.
Description check ✅ Passed The description clearly explains the purpose and context of enforcing erasable TypeScript syntax in the parse-email-address package, with details about Node's native TypeScript capabilities.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch parse-email-address-enable-erasablesyntaxonly-tsconfig

Tip

Try Coding Plans. Let us write the prompt for your AI agent so you can ship faster (with fewer bugs).
Share your feedback on Discord.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@EvanHahn EvanHahn merged commit ab9a8fa into main Mar 4, 2026
34 checks passed
@EvanHahn EvanHahn deleted the parse-email-address-enable-erasablesyntaxonly-tsconfig branch March 4, 2026 19:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant