Skip to content

Migrate from tsup to tsdown#74

Merged
RawToast merged 7 commits intomasterfrom
dependencies
Mar 29, 2026
Merged

Migrate from tsup to tsdown#74
RawToast merged 7 commits intomasterfrom
dependencies

Conversation

@RawToast
Copy link
Copy Markdown
Owner

@RawToast RawToast commented Mar 28, 2026

Summary by CodeRabbit

  • Documentation

    • Clarified build command wording to indicate tsdown as the bundling tool.
  • Chores

    • Bumped dev toolchain and runtime dependencies for updates.
    • Migrated project build tooling to a new bundler and adjusted bundling to preserve native fs usage.
    • Enabled Bun type support and improved module resolution in TypeScript configs.
    • Updated CI workflow action versions.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Mar 28, 2026

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 2c0c39e4-f27c-477b-8d82-a182ecc48052

📥 Commits

Reviewing files that changed from the base of the PR and between a5d82ec and 6d0f52a.

📒 Files selected for processing (1)
  • .github/workflows/publish.yml
✅ Files skipped from review due to trivial changes (1)
  • .github/workflows/publish.yml

📝 Walkthrough

Walkthrough

This PR migrates the zenko package build from tsup to tsdown (scripts and bundler config), adds Bun types to TypeScript configs, bumps several devDependencies in the repo, and updates runtime/dev deps in the examples package. A comment in AGENTS.md was corrected to reference tsdown.

Changes

Cohort / File(s) Summary
Documentation
AGENTS.md
Updated build command comment to state the project uses tsdown (comment text only; command unchanged).
Root devDependencies
package.json
Bumped dev tooling versions: oxfmt, oxlint, oxlint-tsgolint, and turbo. No script changes.
Examples package deps & config
packages/examples/package.json, packages/examples/tsconfig.json
Bumped runtime deps (axios, effect, undici) and dev @types/bun; tsconfig now includes types: ["bun"], moduleResolution: "bundler", removed rootDir, and added a paths alias for zenko.
zenko package build migration
packages/zenko/package.json, packages/zenko/tsconfig.json, packages/zenko/tsdown.config.ts
Replaced tsup with tsdown in build scripts and devDeps; added types: ["bun"] to tsconfig; updated bundler config to use deps.neverBundle for fs and cjsDefault instead of previous external/cjsInterop options.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

Poem

🐰 I hopped from tsup to tsdown with glee,
Bun types tucked in under a tea,
Dependencies nudged, configs set right,
I nibble on builds and dance through the night. ✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'Migrate from tsup to tsdown' accurately and concisely describes the main change across the changeset—replacing the tsup bundler with tsdown in build tooling and configurations.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch dependencies

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 and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🧹 Nitpick comments (1)
packages/examples/package.json (1)

24-24: Update peerDependency to reflect TypeScript 6.x compatibility.

packages/zenko/package.json declares peerDependencies: { "typescript": "^5" }, but packages/examples uses TypeScript 6.0.2. Both tsconfig.json files are already configured correctly for TypeScript 6.x (strict mode enabled, modern module resolution), so the code is compatible.

Consider updating the peerDependency to "^5 || ^6" to accurately reflect that TypeScript 6.x works with the codebase.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/examples/package.json` at line 24, Update the peerDependencies entry
for TypeScript so it reflects compatibility with both v5 and v6: locate the
peerDependencies block where "typescript": "^5" is declared (peerDependencies ->
"typescript") and change the version string to "^5 || ^6" to match the examples
package using "typescript": "6.0.2" and indicate support for TypeScript 6.x.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@packages/zenko/package.json`:
- Around line 69-72: The package.json shows a devDependency on "typescript":
"6.0.2" but peerDependencies lists "typescript": "^5", creating a mismatch;
update the peerDependencies entry for TypeScript in package.json (the
"peerDependencies" block and the "typescript" key) to reflect supported ranges
(for example "^5 || ^6") or confirm and set the single supported major version
to match dev/test (e.g., "^6") to ensure consumers and developers have
consistent TypeScript expectations.

---

Nitpick comments:
In `@packages/examples/package.json`:
- Line 24: Update the peerDependencies entry for TypeScript so it reflects
compatibility with both v5 and v6: locate the peerDependencies block where
"typescript": "^5" is declared (peerDependencies -> "typescript") and change the
version string to "^5 || ^6" to match the examples package using "typescript":
"6.0.2" and indicate support for TypeScript 6.x.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 72a1ec21-bbe4-49df-ae7f-55c647a91900

📥 Commits

Reviewing files that changed from the base of the PR and between 01475a7 and da3d5cc.

⛔ Files ignored due to path filters (1)
  • bun.lock is excluded by !**/*.lock
📒 Files selected for processing (8)
  • AGENTS.md
  • bunfig.toml
  • package.json
  • packages/examples/package.json
  • packages/examples/tsconfig.json
  • packages/zenko/package.json
  • packages/zenko/tsconfig.json
  • packages/zenko/tsdown.config.ts

RawToast and others added 3 commits March 28, 2026 22:48
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
@codecov
Copy link
Copy Markdown

codecov bot commented Mar 29, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.92%. Comparing base (01475a7) to head (6d0f52a).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master      #74   +/-   ##
=======================================
  Coverage   97.92%   97.92%           
=======================================
  Files          16       16           
  Lines        2309     2309           
=======================================
  Hits         2261     2261           
  Misses         48       48           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@RawToast RawToast merged commit ee31d80 into master Mar 29, 2026
6 checks passed
@RawToast RawToast deleted the dependencies branch March 29, 2026 10:37
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.

1 participant