feat: build @nuxt/module-builder using rolldown#730
Conversation
Co-authored-by: Copilot <copilot@github.com>
commit: |
|
Note Reviews pausedIt 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 Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
📝 WalkthroughWalkthroughRemoved the default Unbuild export from Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
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 |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@rolldown.config.ts`:
- Around line 17-22: Add the missing trailing commas to satisfy the linter: in
the rolldown config object add a trailing comma after the dts() entry inside the
plugins array (plugins: [ dts(), ]) and add a trailing comma after the
entryFileNames property value inside the output object (output: {
entryFileNames: '[name].mjs', }), leaving the existing plugins, dts(), output
and entryFileNames identifiers unchanged.
🪄 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: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 6f0c2a97-c234-4eba-9e76-715a4720292e
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (3)
build.config.tspackage.jsonrolldown.config.ts
💤 Files with no reviewable changes (1)
- build.config.ts
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
| input: Object.fromEntries( | ||
| globSync('src/**/*.ts').map(file => [ | ||
| path.relative('src', file.slice(0, file.length - path.extname(file).length)) | ||
| .split(path.sep) | ||
| .join('/'), | ||
| path.resolve(file), | ||
| ]), | ||
| ), |
There was a problem hiding this comment.
we should only need cli + index entries, right?
There was a problem hiding this comment.
Ideally only these two, but rolldown wasn't bundling dynamic imports for some reason.
This approach aligns with https://rolldown.rs/reference/InputOptions.input#in-depth
LMK if you're aware of a better solution.
There was a problem hiding this comment.
🧹 Nitpick comments (1)
package.json (1)
58-59: Move build-only rolldown packages todevDependencies.
rolldownandrolldown-plugin-dtsare used exclusively inrolldown.config.tsand have no runtime imports. Keeping them independenciesunnecessarily increases the install surface for consumers.Proposed dependency move
"dependencies": { @@ - "rolldown": "^1.0.0-rc.18", - "rolldown-plugin-dts": "^0.23.2", "tinyglobby": "^0.2.16", @@ "devDependencies": { + "rolldown": "^1.0.0-rc.18", + "rolldown-plugin-dts": "^0.23.2",🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@package.json` around lines 58 - 59, Move the build-only packages "rolldown" and "rolldown-plugin-dts" from dependencies into devDependencies in package.json; edit package.json to remove the "rolldown" and "rolldown-plugin-dts" entries under "dependencies" and add identical version entries under "devDependencies" (preserving the versions "^1.0.0-rc.18" and "^0.23.2"), then run an install to verify lockfile updates.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In `@package.json`:
- Around line 58-59: Move the build-only packages "rolldown" and
"rolldown-plugin-dts" from dependencies into devDependencies in package.json;
edit package.json to remove the "rolldown" and "rolldown-plugin-dts" entries
under "dependencies" and add identical version entries under "devDependencies"
(preserving the versions "^1.0.0-rc.18" and "^0.23.2"), then run an install to
verify lockfile updates.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: d64bff2a-e743-424f-a48f-74b47a353ff0
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (3)
.gitignorepackage.jsonrolldown.config.ts
✅ Files skipped from review due to trivial changes (1)
- .gitignore
🚧 Files skipped from review as they are similar to previous changes (1)
- rolldown.config.ts
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@package.json`:
- Line 92: The package.json engines field currently sets "node" to ">=22.12.0"
but Rolldown 1.0.0 requires Node >=24.12.0; update the engines entry (the "node"
value) to ">=24.12.0" so the package declares the correct minimum Node.js
version.
🪄 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: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 2f8af358-c3b2-4926-a25c-dfb3f1e13da8
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (1)
package.json
📚 Description
This moves building the Nuxt module builder library itself from unbuild to rolldown. Building userland modules with it using rolldown is the next step.