Skip to content

feat: support output.compareBeforeEmit#8245

Merged
LingyuCoder merged 7 commits intomainfrom
feat/compare-before-emit
Oct 29, 2024
Merged

feat: support output.compareBeforeEmit#8245
LingyuCoder merged 7 commits intomainfrom
feat/compare-before-emit

Conversation

@LingyuCoder
Copy link
Copy Markdown
Contributor

@LingyuCoder LingyuCoder commented Oct 29, 2024

Summary

Align with https://github.com/webpack/webpack/blob/main/lib/Compiler.js#L894-L924

Support output.compareBeforeEmit to avoid write same content to same file what will change the mtime of these files and trigger watcher behavior.

Fix #8093

Checklist

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

@netlify
Copy link
Copy Markdown

netlify bot commented Oct 29, 2024

Deploy Preview for rspack ready!

Name Link
🔨 Latest commit 361f160
🔍 Latest deploy log https://app.netlify.com/sites/rspack/deploys/6720c1c870a3bf00086f8b4a
😎 Deploy Preview https://deploy-preview-8245--rspack.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@github-actions github-actions bot added release: feature release: feature related release(mr only) team The issue/pr is created by the member of Rspack. labels Oct 29, 2024
@LingyuCoder LingyuCoder requested a review from SyMind October 29, 2024 10:07
@LingyuCoder LingyuCoder marked this pull request as ready for review October 29, 2024 10:07
@LingyuCoder
Copy link
Copy Markdown
Contributor Author

!bench

@rspack-bot
Copy link
Copy Markdown

rspack-bot commented Oct 29, 2024

📝 Benchmark detail: Open

Name Base (2024-10-29 a901d54) Current Change
10000_development-mode + exec 2.11 s ± 23 ms 2.13 s ± 41 ms +0.72 %
10000_development-mode_hmr + exec 672 ms ± 22 ms 646 ms ± 6.6 ms -3.79 %
10000_production-mode + exec 2.71 s ± 62 ms 2.71 s ± 37 ms -0.30 %
arco-pro_development-mode + exec 1.78 s ± 66 ms 1.79 s ± 43 ms +0.74 %
arco-pro_development-mode_hmr + exec 430 ms ± 8.4 ms 428 ms ± 2.3 ms -0.53 %
arco-pro_production-mode + exec 3.2 s ± 91 ms 3.21 s ± 77 ms +0.41 %
arco-pro_production-mode_generate-package-json-webpack-plugin + exec 3.23 s ± 81 ms 3.24 s ± 69 ms +0.29 %
threejs_development-mode_10x + exec 1.61 s ± 18 ms 1.62 s ± 18 ms +0.25 %
threejs_development-mode_10x_hmr + exec 765 ms ± 11 ms 770 ms ± 9.8 ms +0.68 %
threejs_production-mode_10x + exec 5.02 s ± 35 ms 5.01 s ± 24 ms -0.17 %

@web-infra-dev web-infra-dev deleted a comment from rspack-bot Oct 29, 2024
@LingyuCoder LingyuCoder enabled auto-merge (squash) October 29, 2024 10:39
SyMind
SyMind previously approved these changes Oct 29, 2024
@LingyuCoder LingyuCoder force-pushed the feat/compare-before-emit branch from 0b54a39 to 361f160 Compare October 29, 2024 11:06
@LingyuCoder LingyuCoder merged commit ef40355 into main Oct 29, 2024
@LingyuCoder LingyuCoder deleted the feat/compare-before-emit branch October 29, 2024 11:24
@Touhami-viseo
Copy link
Copy Markdown

Awesome, thank you very much. I'll test it on my setup ASAP.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release: feature release: feature related release(mr only) team The issue/pr is created by the member of Rspack.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Watch updates whole output files

4 participants