Skip to content

Conversation

@fi3ework
Copy link
Member

@fi3ework fi3ework commented Nov 11, 2024

Summary

Fix #391.
Fix #381.
Fix #166.
Fix #425.

Overview

  • Change the implementation of shim for import.meta.url. Previously, we can't use BannerPlugin to insert it into the top of the bundle as there might be a existing "use strict", inject to the end also does not help as there will be a TDZ. In thi PR, using processAssets hook to insert the shim code to the correct position while preserve the leading "use strict".
  • Preserve the leading shebang directive for chunk entry modules, the implementation refers https://github.com/shuangwhywhy/webpack-shebang-plugin.
  • Preserve the leading React directive for chunk entry modules.

Related Links

Checklist

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

@netlify
Copy link

netlify bot commented Nov 11, 2024

Deploy Preview for rslib ready!

Name Link
🔨 Latest commit 428cfa5
🔍 Latest deploy log https://app.netlify.com/sites/rslib/deploys/673568cf7e9dfc0008e85668
😎 Deploy Preview https://deploy-preview-399--rslib.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.

@fi3ework fi3ework force-pushed the shebang branch 4 times, most recently from 3284409 to d5971e8 Compare November 11, 2024 18:00
@codspeed-hq
Copy link

codspeed-hq bot commented Nov 11, 2024

CodSpeed Performance Report

Merging #399 will not alter performance

Comparing shebang (f4bd86f) with main (096c435)

Summary

✅ 5 untouched benchmarks

@fi3ework fi3ework force-pushed the shebang branch 6 times, most recently from 021b27f to db310bd Compare November 13, 2024 09:56
@fi3ework fi3ework force-pushed the shebang branch 7 times, most recently from a6ddd4d to fc198ad Compare November 14, 2024 04:55
@fi3ework fi3ework force-pushed the shebang branch 3 times, most recently from 3f6e249 to 10633d7 Compare November 14, 2024 05:52
www
@fi3ework fi3ework marked this pull request as ready for review November 14, 2024 06:03
@fi3ework fi3ework marked this pull request as draft November 14, 2024 06:03
@fi3ework fi3ework marked this pull request as ready for review November 14, 2024 10:30
@fi3ework fi3ework merged commit accf40c into main Nov 15, 2024
20 checks passed
@fi3ework fi3ework deleted the shebang branch November 15, 2024 06:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

3 participants