-
Notifications
You must be signed in to change notification settings - Fork 737
Description
What problem does this feature solve?
Currently, generated source maps always include the original untransformed source code in their sourcesContent field. This is useful for more in depth debugging, but when only correct line/column references in errors are required, it's unnecessary bloat in the final bundle when inlining the source maps and prevents obscuring the code with minification.
Both esbuild and rollup have options to leave out sourcesContent. This allows keeping the position references to the original code without having to include it.
What does the proposed API look like?
A boolean property should be added to the output options object. To keep the API similar, naming it either sourcemapExcludeSources like Rollup or sourcesContent like in esbuild would be best.
Of note is that those two existing solutions use opposing values. The Rollup flag removes the sources when true, while esbuild's optins needs to be set to false.
Metadata
Metadata
Assignees
Type
Fields
Give feedbackPriority
Start date
Target date
Effort