fix: adapt preact files to the new extensions#247
Conversation
📝 WalkthroughWalkthroughA build configuration change in rollup.js updates preact entry file resolution patterns, switching from Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~2 minutes Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Pull request overview
This PR updates the preact build script to align with a breaking change in v16 where the output file extensions for CommonJS and ES modules were changed. The build system now generates .cjs and .mjs extensions instead of .js for these module formats, resulting in filenames like *.cjs.cjs and *.esm.mjs.
Changes:
- Updated glob patterns in the preact build script to match the new file extensions (
.cjs.cjsfor CommonJS and.esm.mjsfor ES modules)
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
Thanks @silviuaavram ! |
|
@kentcdodds I feel this is actually a fix to the v16 breaking change. Do you have any project that uses preact? |
|
You're right, probably didn't need to make it a breaking change. But meh. 😅 I'm fixing the release script right now. A new release should be published soon. |
|
🎉 This PR is included in version 17.0.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
What:
With the breaking change of v16, the cjs and esm file extensions changed from .js to .cjs and .mjs. The
preactscript also needs to be updated.Why:
Downshift uses kcd-scripts, and we keep supporting preact.
How:
Change the strings.
Checklist:
Summary by CodeRabbit