Skip to content

chore: remove divider comment from output#12109

Merged
chenjiahan merged 1 commit intomainfrom
remove_divider_comment_1106
Nov 6, 2025
Merged

chore: remove divider comment from output#12109
chenjiahan merged 1 commit intomainfrom
remove_divider_comment_1106

Conversation

@chenjiahan
Copy link
Copy Markdown
Member

@chenjiahan chenjiahan commented Nov 6, 2025

Summary

This PR removes the /************************************************************************/ divider comment from Rspack’s generated bundles to simplify the generated output.

The comment originated from webpack's template as a visual separator. It has no functional or semantic purpose today.

Related links

Checklist

  • Tests updated (or not required).
  • Documentation updated (or not required).

Copilot AI review requested due to automatic review settings November 6, 2025 10:36
@netlify
Copy link
Copy Markdown

netlify bot commented Nov 6, 2025

Deploy Preview for rspack canceled.

Name Link
🔨 Latest commit 174c35f
🔍 Latest deploy log https://app.netlify.com/projects/rspack/deploys/690c7a3cb55dee0008ce9f0c

@github-actions github-actions bot added the team The issue/pr is created by the member of Rspack. label Nov 6, 2025
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR removes visual separator comments (/************************************************************************/) from the generated JavaScript bundle output, resulting in cleaner and slightly smaller bundles.

Key Changes

  • Removed three instances of separator comment additions in the JavaScript plugin rendering logic
  • Updated all affected test snapshots to reflect the cleaner output format
  • Bundle sizes decreased marginally due to the removal of these comment lines

Reviewed Changes

Copilot reviewed 25 out of 25 changed files in this pull request and generated no comments.

Show a summary per file
File Description
crates/rspack_plugin_javascript/src/plugin/mod.rs Removed separator comment additions after webpack modules, header, and runtime modules sections
tests/rspack-test/statsOutputCases/worker-public-path/snapshots/stats.txt Updated hash value reflecting output change
tests/rspack-test/statsOutputCases/warnings-space-warning/snapshots/stats.txt Updated bundle size from 782 to 632 bytes
tests/rspack-test/statsOutputCases/split-chunks/snapshots/stats.txt Updated entrypoint size from xx KiB to 9 KiB
tests/rspack-test/statsOutputCases/preset-none-error/snapshots/stats.txt Updated bundle size from 924 to 774 bytes
tests/rspack-test/statsOutputCases/performance-no-async-chunks-shown/snapshots/stats.txt Updated asset and entrypoint sizes to reflect separator removal
tests/rspack-test/statsOutputCases/max-external-module-readable-identifier/snapshots/stats.txt Updated bundle size from xx KiB to 927 bytes
tests/rspack-test/statsOutputCases/external/snapshots/stats.txt Updated bundle size from 998 to 848 bytes
tests/rspack-test/statsAPICases/chunk-group.js Updated entrypoint size assertion from 13.6 KiB to 13.4 KiB
tests/rspack-test/hookCases/normalModuleFactory#resolve/resource/output.snap.txt Removed separator comments from generated output
tests/rspack-test/hookCases/normalModuleFactory#afterResolve/resource/output.snap.txt Removed separator comments from generated output
tests/rspack-test/hookCases/normalModuleFactory#afterResolve/request/output.snap.txt Removed separator comments from generated output
tests/rspack-test/hookCases/normalModuleFactory#afterResolve/duplicate/output.snap.txt Removed separator comments from generated output
tests/rspack-test/hookCases/javascriptModulesPlugin#chunkHash/update-hash/output.snap.txt Removed separator comments from generated output
tests/rspack-test/hookCases/compiler#assetEmitted/basic/output.snap.txt Removed separator comments from generated output
tests/rspack-test/hookCases/compilation#processAssets/update-asset/output.snap.txt Updated hash and removed separator comments
tests/rspack-test/hookCases/compilation#chunkHash/update-hash/output.snap.txt Removed separator comments from generated output
tests/rspack-test/hookCases/compilation#afterProcessAssets/basic/output.snap.txt Removed separator comments from generated output
tests/rspack-test/configCases/rsdoctor/assets/rspack.config.js Updated asset sizes from 4229 to 4004 bytes
tests/rspack-test/configCases/library/render-order-issue/snapshots/entry.mjs.txt Removed separator comments from generated output
tests/rspack-test/configCases/library/modern-module-force-concaten/snapshot/g.js.txt Removed separator comments from generated output
tests/rspack-test/configCases/library/modern-module-force-concaten/snapshot/f.js.txt Removed separator comments from generated output
tests/rspack-test/configCases/library/modern-module-force-concaten/snapshot/e.js.txt Removed separator comments from generated output
tests/rspack-test/configCases/library/modern-module-force-concaten/snapshot/b.js.txt Removed separator comments from generated output
tests/rspack-test/builtinCases/plugin-html/variant/snapshots/output.snap.txt Updated integrity hash reflecting output change

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Nov 6, 2025

📦 Binary Size-limit

Comparing 174c35f to test: enable more watch cases (#12106) by harpsealjs

🎉 Size decreased by 512bytes from 47.89MB to 47.89MB (⬇️0.00%)

@codspeed-hq
Copy link
Copy Markdown

codspeed-hq bot commented Nov 6, 2025

CodSpeed Performance Report

Merging #12109 will not alter performance

Comparing remove_divider_comment_1106 (174c35f) with main (c891a13)

Summary

✅ 17 untouched

@chenjiahan chenjiahan enabled auto-merge (squash) November 6, 2025 11:25
@chenjiahan chenjiahan merged commit 6d5dbd3 into main Nov 6, 2025
78 of 81 checks passed
@chenjiahan chenjiahan deleted the remove_divider_comment_1106 branch November 6, 2025 12:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

team The issue/pr is created by the member of Rspack.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants