Skip to content

fix(infra): emit declarations for rebuild:types (SD-2925)#3109

Merged
caio-pizzol merged 1 commit into
mainfrom
caio/sd-2925-rebuildtypes-fails-because-geometry-utils-build-does-not
May 4, 2026
Merged

fix(infra): emit declarations for rebuild:types (SD-2925)#3109
caio-pizzol merged 1 commit into
mainfrom
caio/sd-2925-rebuildtypes-fails-because-geometry-utils-build-does-not

Conversation

@caio-pizzol

Copy link
Copy Markdown
Contributor

What changed

  • Make @superdoc/geometry-utils and @superdoc/dom-contract emit declaration artifacts during their package build.
  • Keep each package's TypeScript build info under dist/ so deleting generated output also resets incremental state.
  • Serialize pnpm run rebuild:types enough that declaration producers build before @superdoc/painter-dom, avoiding the layout-bridge / painter-dom cycle race.

Why

pnpm run rebuild:types failed in a clean worktree because @superdoc/measuring-dom project-references @superdoc/geometry-utils and expects geometry-utils/dist/index.d.ts to exist. The package tsconfig declared composite declaration output, but the build script used --noEmit, so the referenced declaration output was never written.

After fixing geometry-utils, the same mismatch surfaced for @superdoc/dom-contract, and the root rebuild script could still run painter-dom before layout-bridge had emitted its declarations. This PR fixes the declaration producers and the rebuild ordering.

Verification

  • pnpm run rebuild:types
  • pnpm run type-check
  • git diff --check

@linear

linear Bot commented May 4, 2026

Copy link
Copy Markdown

@codecov-commenter

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@caio-pizzol
caio-pizzol marked this pull request as ready for review May 4, 2026 13:43
@caio-pizzol
caio-pizzol requested a review from a team as a code owner May 4, 2026 13:43
@caio-pizzol
caio-pizzol merged commit 06d8624 into main May 4, 2026
77 of 78 checks passed
@caio-pizzol
caio-pizzol deleted the caio/sd-2925-rebuildtypes-fails-because-geometry-utils-build-does-not branch May 4, 2026 13:43
@superdoc-bot

superdoc-bot Bot commented May 4, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in @superdoc-dev/mcp v0.3.0-next.37

The release is available on GitHub release

@superdoc-bot

superdoc-bot Bot commented May 4, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in vscode-ext v2.3.0-next.81

@superdoc-bot

superdoc-bot Bot commented May 4, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in @superdoc-dev/react v1.2.0-next.79

The release is available on GitHub release

@superdoc-bot

superdoc-bot Bot commented May 4, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in superdoc-cli v0.8.0-next.55

The release is available on GitHub release

@superdoc-bot

superdoc-bot Bot commented May 4, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in superdoc v1.30.0-next.38

The release is available on GitHub release

@superdoc-bot

superdoc-bot Bot commented May 4, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in superdoc-sdk v1.8.0-next.40

@superdoc-bot

superdoc-bot Bot commented May 7, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in superdoc-cli v0.9.0

The release is available on GitHub release

@superdoc-bot

superdoc-bot Bot commented May 7, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in superdoc v1.32.0

The release is available on GitHub release

@superdoc-bot

superdoc-bot Bot commented May 7, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in @superdoc-dev/mcp v0.4.0

The release is available on GitHub release

@superdoc-bot

superdoc-bot Bot commented May 7, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in @superdoc-dev/react v1.3.0

The release is available on GitHub release

@superdoc-bot

superdoc-bot Bot commented May 7, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in vscode-ext v2.4.0

@superdoc-bot

superdoc-bot Bot commented May 15, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in superdoc-sdk v1.9.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants