Skip to content

ci(create): assert the monorepo library emits declarations#2171

Open
wan9chi wants to merge 1 commit into
mainfrom
ci/monorepo-dts-gate
Open

ci(create): assert the monorepo library emits declarations#2171
wan9chi wants to merge 1 commit into
mainfrom
ci/monorepo-dts-gate

Conversation

@wan9chi

@wan9chi wan9chi commented Jul 14, 2026

Copy link
Copy Markdown
Member

Summary

Adds a declaration-output assertion to the vp create monorepo CI jobs: after vp run ready, packages/utils/dist/index.d.mts must exist.

Why

A green vp run ready only proves the build exited 0. Declaration generation can degrade silently — generator skipped, output landing in the wrong place — while the exit code stays clean, which would ship type-less libraries from every freshly created monorepo without CI noticing.

Since #2168 the monorepo template scaffolds TypeScript 7, so the utils library's vp pack runs dts through tsdown's native-compiler (tsgo) path — the machinery that broke in #2160. This assertion turns the four create jobs into an end-to-end regression gate for that path across pnpm/npm/yarn/bun.

Notes

  • The emitted file is index.d.mts (paired with the ESM index.mjs bundle), not index.d.ts — verified against a local-registry build of main:
    ℹ Emit types with typescript@7.0.2
    ℹ dist/index.mjs    0.10 kB
    ℹ dist/index.d.mts  0.08 kB
    

🤖 Generated with Claude Code

A green `vp run ready` proves the build exited 0, but declaration
generation can degrade silently (skipped generator, wrong output
location) while the exit code stays clean. Pin the deliverable: after
the build, packages/utils/dist/index.d.mts must exist.

With the monorepo template now scaffolding TypeScript 7 (#2168), this
makes the create jobs an end-to-end regression gate for the native
compiler (tsgo) dts path that broke in #2160. Verified against a real
local-registry build: `vp pack` emits dist/index.d.mts (not .d.ts)
next to the ESM bundle.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@netlify

netlify Bot commented Jul 14, 2026

Copy link
Copy Markdown

Deploy Preview for viteplus-preview canceled.

Name Link
🔨 Latest commit 71c13e8
🔍 Latest deploy log https://app.netlify.com/projects/viteplus-preview/deploys/6a56013cc4680b0007d275b9

@wan9chi wan9chi added test: e2e Auto run e2e tests test: install-e2e run vite install e2e test test: sfw test: create-e2e Run `vp create` e2e tests labels Jul 14, 2026
@wan9chi wan9chi requested a review from cpojer July 14, 2026 09:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

test: create-e2e Run `vp create` e2e tests test: e2e Auto run e2e tests test: install-e2e run vite install e2e test test: sfw

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant