Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat!: add shims config #291

Merged
merged 10 commits into from
Oct 15, 2024
Merged

feat!: add shims config #291

merged 10 commits into from
Oct 15, 2024

Conversation

fi3ework
Copy link
Member

@fi3ework fi3ework commented Oct 15, 2024

Summary

💥 Breaking changes:

  • __dirname and __filename won't be shimmed in ESM output by default. Set lib.shims.esm.__dirname and lib.shims.esm.__filename to true to enable.

Related Links

Checklist

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

Copy link

netlify bot commented Oct 15, 2024

Deploy Preview for rslib ready!

Name Link
🔨 Latest commit 76eb4f0
🔍 Latest deploy log https://app.netlify.com/sites/rslib/deploys/670e25c42174030008a88a3f
😎 Deploy Preview https://deploy-preview-291--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.

Copy link

codspeed-hq bot commented Oct 15, 2024

CodSpeed Performance Report

Merging #291 will not alter performance

Comparing fix-shim (c916741) with main (3419b1a)

Summary

✅ 3 untouched benchmarks

@Timeless0911
Copy link
Collaborator

The PR title can be a feature about adding shims config.

@fi3ework fi3ework changed the title fix: do not use CJS methods in ESM feat: add shims config Oct 15, 2024
@Timeless0911 Timeless0911 changed the title feat: add shims config feat!: add shims config Oct 15, 2024
packages/core/src/config.ts Outdated Show resolved Hide resolved
packages/core/src/plugins/shims.ts Outdated Show resolved Hide resolved
packages/core/src/plugins/shims.ts Outdated Show resolved Hide resolved
packages/core/src/types/config/index.ts Outdated Show resolved Hide resolved
packages/core/tests/__snapshots__/config.test.ts.snap Outdated Show resolved Hide resolved
Copy link
Collaborator

@Timeless0911 Timeless0911 left a comment

Choose a reason for hiding this comment

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

LGTM

@Timeless0911 Timeless0911 enabled auto-merge (squash) October 15, 2024 09:18
@Timeless0911 Timeless0911 merged commit da145e9 into main Oct 15, 2024
18 checks passed
@Timeless0911 Timeless0911 deleted the fix-shim branch October 15, 2024 09:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants