-
-
Notifications
You must be signed in to change notification settings - Fork 1
breaking: drop cjs #13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Warning Rate limit exceeded@kazupon has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 20 minutes and 39 seconds before requesting another review. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. 📒 Files selected for processing (9)
WalkthroughMigrate h3 and hono from Unbuild to Tsdown: remove Unbuild build configs, add Tsdown configs, change package exports to ESM (.mjs/.mts), update build scripts and workspace catalog, plus minor docs/test/text fixes and a .gitignore entry. Changes
Sequence Diagram(s)sequenceDiagram
autonumber
participant Dev as Developer
participant CLI as package.json (scripts)
participant Tsdown as Tsdown
participant FS as File System
Dev->>CLI: run `pnpm build` (now uses tsdown)
CLI->>Tsdown: invoke tsdown with config (tsdown.config.ts)
Tsdown->>FS: read `./src/index.ts` and other entries
Tsdown->>FS: emit ESM bundles (`dist/index.mjs`) and types (`dist/*.d.mts`)
Tsdown-->>CLI: exit (success / publint warnings)
CLI-->>Dev: build result
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes
Poem
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
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. Comment |
commit: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 2
♻️ Duplicate comments (1)
packages/h3/tsdown.config.ts (1)
1-12: Configuration is identical to hono package.This configuration duplicates
packages/hono/tsdown.config.ts. See the review comment on that file for a suggestion to extract shared configuration.
🧹 Nitpick comments (1)
packages/hono/tsdown.config.ts (1)
1-12: Consider extracting shared tsdown configuration to reduce duplication.The configuration is identical to
packages/h3/tsdown.config.ts. Consider creating a shared base configuration file (e.g.,tsdown.base.config.tsat the workspace root) that both packages can extend.Example shared configuration:
// tsdown.base.config.ts (at workspace root) import type { UserConfig } from 'tsdown' export const baseConfig: UserConfig = { entry: ['./src/index.ts'], outDir: 'dist', clean: true, publint: true }Then in each package:
import { defineConfig } from 'tsdown' - -import type { UserConfig } from 'tsdown' - -const config: UserConfig = defineConfig({ - entry: ['./src/index.ts'], - outDir: 'dist', - clean: true, - publint: true -}) +import { baseConfig } from '../../tsdown.base.config' -export default config +export default defineConfig(baseConfig)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (7)
packages/h3/build.config.ts(0 hunks)packages/h3/package.json(2 hunks)packages/h3/tsdown.config.ts(1 hunks)packages/hono/build.config.ts(0 hunks)packages/hono/package.json(2 hunks)packages/hono/tsdown.config.ts(1 hunks)pnpm-workspace.yaml(1 hunks)
💤 Files with no reviewable changes (2)
- packages/h3/build.config.ts
- packages/hono/build.config.ts
🔇 Additional comments (7)
packages/h3/package.json (3)
52-59: LGTM: typesVersions configuration is appropriate.The
typesVersionsfield correctly provides TypeScript with fallback paths for type resolution. The wildcard mapping todist/*and root files is a standard pattern for ESM packages.
61-61: LGTM: Build script updated to use tsdown.The build script change from
unbuildtotsdownis consistent with the migration and the newtsdown.config.tsconfiguration file.
74-76: LGTM: devDependencies updated for new build tooling.The addition of
publintandtsdownas devDependencies is appropriate for the migration. Using catalog versions ensures consistency across the workspace.packages/hono/package.json (3)
51-58: LGTM: typesVersions configuration is appropriate.The
typesVersionsfield correctly provides TypeScript with fallback paths for type resolution. The wildcard mapping is consistent with the h3 package and follows standard ESM package patterns.
60-60: LGTM: Build script updated to use tsdown.The build script change from
unbuildtotsdownis consistent with the migration and the newtsdown.config.tsconfiguration file.
73-74: LGTM: devDependencies updated for new build tooling.The addition of
publintandtsdownas devDependencies is appropriate for the migration. Using catalog versions ensures consistency across the workspace.pnpm-workspace.yaml (1)
9-10: No action required—versions are valid and current.The specified versions are confirmed as the latest available in the npm registry with no known security vulnerabilities:
tsdown@0.16.4is the current latest versionpublint@0.3.15is the current latest versionBoth caret constraints (
^) appropriately allow compatible upgrades per semver.
Description
Linked Issues
Additional context
Summary by CodeRabbit
Build System Updates
Documentation
Tests
Chores