-
-
Notifications
You must be signed in to change notification settings - Fork 782
Closed
webpack/webpack
#18713Labels
featNew feature or requestNew feature or requeststaleteamThe issue/pr is created by the member of Rspack.The issue/pr is created by the member of Rspack.
Description
What problem does this feature solve?
currently rspack | webpack will generate the following result for modern-module, the comment is not nicely(Concate module seems hard to understand for normal users) to read, even minifier can remove these comments, but normally library code shouldn't be minified for better debug experience
;// CONCATENATED MODULE: ./src/answer.js
const answer = 42;
;// CONCATENATED MODULE: ./src/secret.js
const secret = 'rspack';
;// CONCATENATED MODULE: ./src/index.js
export { answer, secret };
//# sourceMappingURL=index.mjs.mapWhat does the proposed API of configuration look like?
there're some solutions, i'm not sure which is better
- provide a option to remove comments (like rollup don't have this annotation)
{
output: {
keepDebugComments: boolean // true means keep, false means remove
}
}- provide better comment annotation(like esbuild provide the simplest annotation)
./src/answer.js
const answer = 42;
./src/secret.js
const secret = 'rspack';
./src/index.jsReactions are currently unavailable
Metadata
Metadata
Assignees
Labels
featNew feature or requestNew feature or requeststaleteamThe issue/pr is created by the member of Rspack.The issue/pr is created by the member of Rspack.