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

fix: 🐛 export MARKS and EMPTY_DOCUMENT as ESM friendly #462

Merged
merged 3 commits into from
Mar 4, 2024
Merged

fix: 🐛 export MARKS and EMPTY_DOCUMENT as ESM friendly #462

merged 3 commits into from
Mar 4, 2024

Conversation

mika-f
Copy link
Contributor

@mika-f mika-f commented May 7, 2023

MARKS and EMPTY_DOCUMENT are not exports in a format that supports in ESM, so using them in a project with type: module will result in an error like the one below:

error Named export 'MARKS' not found. The requested module '@contentful/rich-text-types' is a CommonJS module, which may not support all module.exports as named exports.

This PR fixes modules that are export default and default as XXX to named exports, allowing ESN project to build.
This may solve issue #395.

@YvesRijckaert YvesRijckaert merged commit 7ea8ab3 into contentful:master Mar 4, 2024
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants