-
Notifications
You must be signed in to change notification settings - Fork 62
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
Use of rehype-parse
causes CommonJS builds to fail
#345
Comments
Hi there, thank you so much for the report! Following our Maintenance Process, we will review your bug report and get back to you next Wednesday. To ensure a smooth review of your issue and avoid unnecessary delays, please make sure your issue includes the following:
If you have identified the cause of the bug described in your report and know how to fix it, you're more than welcome to open a pull request addressing it. Check out our quick start guide for a simple contribution process. If you think your issue is a question (not a bug) and would like quicker support, please close this issue and forward it to an appropriate section on our community forum: https://community.prismic.io - The Prismic Open-Source Team |
Hi @strmer15, thanks for contributing and bringing this issue to our attention. I'm curious if you can share more about your webpack setup? Which framework you're using, meta-framework if any, etc. We'll release a fix for this tomorrow, in the meantime, pinning Thank you for your understanding 🙏 |
Thanks for getting back to me! We're using Webpack 5 and Typescript 5.5 with React 18, just a custom config that has |
Hey @strmer15, just letting you know we're aligning on a strategy to fix this issue durably so we might need a few extra days to release this fix (I'm expecting Wednesday, definitely this week) to prevent confusion and additional back-and-forth and between the solutions we're envisaging (non-exhaustively: inlining ESM-only dependencies to CJS, exporting the new utilities we introduced to a dedicated package) Is it alright for you to remain on |
Hey @lihbr ! No problem, there's no rush here on our part - we're good being on 7.6.0 for a while. Definitely make sure you take all the time you need to come up with the right fix, thanks! |
Hi @strmer15, this should be fixed with
Thanks for your patience! 🙏 Feel free to reopen if you still experience the same trouble. |
Versions
Reproduction
Get the latest version of
@prismicio/client
and use it in a CommonJS build with Webpack.Additional Details
Steps to reproduce
Use
@prismicio/client
7.7.x in a CommonJS build with Webpack.What is expected?
I can use
@prismicio/client
in a CommonJS Webpack build without any errors.What is actually happening?
It's throwing
ERR_REQUIRE_ESM
when trying to loadrehype-parse
. Therehype-parse
package is ESM only, so by including it this package has essentially become ESM only.The text was updated successfully, but these errors were encountered: