Skip to content

feat: polyfill to enable node sourcemaps#511

Merged
pi0 merged 2 commits intomainfrom
feat/sourcemap-polyfill
Jul 26, 2025
Merged

feat: polyfill to enable node sourcemaps#511
pi0 merged 2 commits intomainfrom
feat/sourcemap-polyfill

Conversation

@pi0
Copy link
Member

@pi0 pi0 commented Jul 26, 2025

This PR adds a new unenv/polyfill/node/source-maps that enables node --enable-source-maps effect in recent Node.js versions (22.14+, 23.7+).

It is a no-op in other environments.

Docs: https://nodejs.org/api/module.html#modulesetsourcemapssupportenabled-options

For legacy (Node.js 20, which is in maintenance till April 2026, ~10 months more), one can use source-map-support with source-map-support/register as an alternative polyfill.

@pi0 pi0 changed the title feat: polyfill to enable sourcemaps feat: polyfill to enable node sourcemaps Jul 26, 2025
@pi0 pi0 merged commit 1651686 into main Jul 26, 2025
2 checks passed
@pi0 pi0 deleted the feat/sourcemap-polyfill branch July 26, 2025 11:52
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