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

chore: switch esbuild output format from iife to esm #6647

Closed
wants to merge 1 commit into from

Conversation

wojtekmaj
Copy link
Contributor

What's the problem this PR addresses?

This setting currently blocks Berry from using ESM modules that use top-level await (e.g. ink).

How did you fix it?

Switching output format to esm seems to be fixing it, while the executable still works.

Checklist

  • I have set the packages that need to be released for my changes to be effective.
  • I will check that all automated PR checks pass before the PR gets reviewed.

This setting currently blocks Berry from using ESM modules that use top-level await (e.g. ink).
Copy link
Member

@arcanis arcanis left a comment

Choose a reason for hiding this comment

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

Various things (of the top of my mind, yarn set version, whose generated file is yarn-x.y.z.cjs) expect the Yarn build to be a CJS file; we can't migrate to ESM without a major release.

@wojtekmaj
Copy link
Contributor Author

Oh darn! I have so many improvements in my mind that would require ESM builds. Well, please consider switching to ESM in the next major then!

@wojtekmaj wojtekmaj closed this Jan 7, 2025
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.

2 participants