Skip to content

perf(dev): use builtin node SourceMap instead of source-map-js - #1430

Merged
danielroe merged 2 commits into
mainfrom
perf/sourcemap
Aug 4, 2026
Merged

perf(dev): use builtin node SourceMap instead of source-map-js#1430
danielroe merged 2 commits into
mainfrom
perf/sourcemap

Conversation

@danielroe

Copy link
Copy Markdown
Member

🔗 Linked issue

📚 Description

this uses native node SourceMap support to drop a dependency (136 KB) from installed size. it's been backported to node v12.17 and is stable.

@danielroedanielroe self-assigned this Aug 4, 2026
@pkg-pr-new

pkg-pr-newBot commented Aug 4, 2026

Copy link
Copy Markdown
  • nuxt-cli-playground

    npm i https://pkg.pr.new/create-nuxt@1430
    
    npm i https://pkg.pr.new/nuxi@1430
    
    npm i https://pkg.pr.new/@nuxt/cli@1430
    

commit: aba4fb7

@codspeed-hq

codspeed-hqBot commented Aug 4, 2026

Copy link
Copy Markdown

Merging this PR will not alter performance

✅ 2 untouched benchmarks


Comparing perf/sourcemap (aba4fb7) with main (3eea4bc)

Open in CodSpeed

@coderabbitai

coderabbitaiBot commented Aug 4, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 4e4cdf1a-2183-45a8-bdf0-f2168ff9d2b0

📥 Commits

Reviewing files that changed from the base of the PR and between ee1323f and aba4fb7.

📒 Files selected for processing (1)
  • packages/nuxt-cli/test/unit/errors.spec.ts
🚧 Files skipped from review as they are similar to previous changes (1)
  • packages/nuxt-cli/test/unit/errors.spec.ts

📝 Walkthrough

Walkthrough

The CLI replaces source-map-js with Node.js SourceMap for stack frame mapping. It exports applySourceMap and adjusts source map entry and position handling. Unit tests cover mapped frames, sourceRoot, and unmapped frames. Package and bundle configuration no longer include source-map-js.

Estimated code review effort: 2 (Simple) | ~10 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check nameStatusExplanation
Title check✅ PassedThe title clearly identifies the main change: replacing the external source-map-js dependency with Node's built-in SourceMap API.
Description check✅ PassedThe description relates directly to the dependency removal and use of native Node SourceMap support.
Docstring Coverage✅ PassedNo functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check✅ PassedCheck skipped because no linked issues were found for this pull request.
Out of Scope Changes check✅ PassedCheck skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch perf/sourcemap

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.

@danielroe
danielroe added this pull request to the merge queueAug 4, 2026
Merged via the queue into main with commit 79d4ad4Aug 4, 2026
19 checks passed
@danielroe
danielroe deleted the perf/sourcemap branch August 4, 2026 10:33
@github-actionsgithub-actionsBot mentioned this pull request Aug 2, 2026
This was referenced Aug 24, 2026
Sign up for freeto 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

@danielroe