Skip to content

feat: restore deprecated TypeScript 7.0 tsgo CLI backend - #331

Merged
sxzz merged 3 commits into
mainfrom
feat/tsgo-ts70-cli
Oct 29, 2026
Merged

sxzz merged 3 commits into
mainfrom
feat/tsgo-ts70-cli

Conversation

@sxzzbot

@sxzzbot sxzzbot commented Oct 29, 2026 •

Copy link
Copy Markdown
Collaborator

AI usage

  • No AI was used in this PR.
  • AI was used: Claude Code + Sonnet 5.5 / Opus 5.5
    • I have carefully reviewed the AI-generated content myself.

Description

The tsgo generator now uses the declaration emit API from TypeScript 7.1+, so TypeScript 7.0 (supported in v0.28 through the tsgo CLI) stopped working.

This restores the v0.28 CLI backend as a deprecated fallback. If the installed typescript is 7.0.x, tsgo runs the CLI. Otherwise it uses the 7.1+ API. With 7.0, the plugin logs a deprecation warning instead of the generic experimental warning. The backend will be removed in the next minor.

The CLI backend does not support custom languages, and among the tsgo.* options only tsgo.path applies. Here it points to the tsgo executable. @typescript/native-preview is not supported.

Linked Issues

Additional context

src/generator/tsgo-cli.ts is mostly unchanged from v0.28.8. It has not been run against a real TypeScript 7.0 install. Only mocked tests cover it.

@pkg-pr-new

pkg-pr-new Bot commented Oct 29, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

npm i https://pkg.pr.new/sxzz/rolldown-plugin-dts@331

commit: 3c68aac

@sxzz
sxzz merged commit 8408fe1 into main Oct 29, 2026
12 checks passed
@sxzz
sxzz deleted the feat/tsgo-ts70-cli branch October 29, 2026 12:53
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.

2 participants