Skip to content

fix(build): support decorator metadata with TypeScript 7 - #4505

Open
carderne wants to merge 4 commits into
ts7from
feature/tri-12948-support-emitdecoratormetadata-with-typescript-7
Open

fix(build): support decorator metadata with TypeScript 7#4505
carderne wants to merge 4 commits into
ts7from
feature/tri-12948-support-emitdecoratormetadata-with-typescript-7

Conversation

@carderne

Copy link
Copy Markdown
Collaborator

Summary

Allow projects using TypeScript 7 to enable emitDecoratorMetadata() without adding the TypeScript 6 compiler to every Trigger.dev CLI installation. Addresses #4500.

Fix

The extension now resolves TypeScript from the project and feature-detects the legacy compiler API. TypeScript 5 and 6 continue using the project's compiler, while TypeScript 7 projects can install Microsoft's optional @typescript/typescript6 compatibility package alongside TypeScript 7.

When no compatible compiler API is available, the build reports an actionable installation error. The extension documentation includes setup commands for npm, pnpm, and Bun.

Verified with TypeScript 5, TypeScript 6, TypeScript 7 with and without the compatibility package, emitted decorator metadata, packed ESM and CommonJS consumers, package export checks, and typechecking.

@changeset-bot

changeset-botBot commented Aug 5, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 87ed753

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes changesets to release 27 packages
NameType
trigger.devPatch
@trigger.dev/buildPatch
@trigger.dev/corePatch
@trigger.dev/pythonPatch
@trigger.dev/react-hooksPatch
@trigger.dev/redis-workerPatch
@trigger.dev/rscPatch
@trigger.dev/schema-to-jsonPatch
@trigger.dev/sdkPatch
@internal/dashboard-agentPatch
@internal/cachePatch
@internal/clickhousePatch
@internal/llm-model-catalogPatch
@internal/metrics-pipelinePatch
@trigger.dev/rbacPatch
@internal/redisPatch
@internal/replicationPatch
@internal/run-enginePatch
@internal/run-storePatch
@internal/schedule-enginePatch
@trigger.dev/ssoPatch
@internal/testcontainersPatch
@internal/tracingPatch
@internal/tsqlPatch
@internal/sdk-compat-testsPatch
@trigger.dev/databasePatch
@trigger.dev/otlp-importerPatch

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@coderabbitai

coderabbitaiBot commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 7f46b537-d831-4838-bd5c-5826845b8de6

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

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.

@pkg-pr-new

pkg-pr-newBot commented Aug 5, 2026

Copy link
Copy Markdown

Open in StackBlitz

@trigger.dev/build

npm i https://pkg.pr.new/@trigger.dev/build@87ed753

trigger.dev

npm i https://pkg.pr.new/trigger.dev@87ed753

@trigger.dev/core

npm i https://pkg.pr.new/@trigger.dev/core@87ed753

@trigger.dev/python

npm i https://pkg.pr.new/@trigger.dev/python@87ed753

@trigger.dev/react-hooks

npm i https://pkg.pr.new/@trigger.dev/react-hooks@87ed753

@trigger.dev/redis-worker

npm i https://pkg.pr.new/@trigger.dev/redis-worker@87ed753

@trigger.dev/rsc

npm i https://pkg.pr.new/@trigger.dev/rsc@87ed753

@trigger.dev/schema-to-json

npm i https://pkg.pr.new/@trigger.dev/schema-to-json@87ed753

@trigger.dev/sdk

npm i https://pkg.pr.new/@trigger.dev/sdk@87ed753

commit: 87ed753

@carderne
carderneforce-pushed the feature/tri-12948-support-emitdecoratormetadata-with-typescript-7 branch from 31e8cc5 to bc095a4CompareAugust 5, 2026 08:50
@carderne
carderne marked this pull request as ready for review August 5, 2026 09:00
devin-ai-integration[bot]

This comment was marked as resolved.

@devin-ai-integrationdevin-ai-integrationBot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 new potential issue.

Open in Devin Review

Comment threadpackages/build/src/extensions/typescript.ts
Sign up for freeto 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

@carderne