fix: externalize @deepnote/blocks types in convert and reactivity packages#213
fix: externalize @deepnote/blocks types in convert and reactivity packages#213
Conversation
📝 WalkthroughWalkthroughThis PR consolidates tsdown build configuration by extracting it from package.json scripts into dedicated config files. The convert and reactivity packages each receive a new tsdown.config.ts file specifying entry points, output formats (ESM and CJS), declaration generation, and external dependencies. Corresponding build and watch scripts are simplified to plain tsdown invocations. Package versions are incremented, and .pnpm-store is added to .gitignore. 🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. 📜 Recent review detailsConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Disabled knowledge base sources:
📒 Files selected for processing (5)
🧰 Additional context used📓 Path-based instructions (1)**/*.{ts,tsx}📄 CodeRabbit inference engine (CLAUDE.md)
Files:
🔇 Additional comments (5)
✏️ Tip: You can disable this entire section by setting Comment |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #213 +/- ##
=======================================
Coverage 91.57% 91.57%
=======================================
Files 41 41
Lines 2041 2041
Branches 630 630
=======================================
Hits 1869 1869
Misses 172 172 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Summary
@deepnote/blockstypes were bundled inline instead of being importedtsdown.config.tsto@deepnote/convertand@deepnote/reactivitywithexternal: ['@deepnote/blocks']Problem
The bundled
.d.tsfiles contained inline copies of types from@deepnote/blocks, causing type incompatibility for consumers using both packages:Solution
Configure tsdown to treat
@deepnote/blocksas external, so generated.d.tsfiles import types instead of bundling them inline.Before:
dist/index.d.ts~646 KB (convert), ~179 KB (reactivity)After:
dist/index.d.ts~23 KB (convert), ~5 KB (reactivity)Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.