-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
ERR_REQUIRE_ESM on build when using Yarn v1. Incorrect dep resolution. #4109
Comments
Looks like this is a yarn v1 package alias resolution issue: yarnpkg/yarn#4812 Closed as won't fix for Yarn v1 😒 |
Only workaround for yarn is to use this in the application's package.json: "resolutions": {
"jackspeak": "2.1.1"
} |
Another avenue would be to update our templates to use yarn v2 and then specify as such in their "engines": {
"yarn": "2.x"
} https://devcenter.heroku.com/articles/nodejs-support#specifying-a-yarn-version |
This issue has been automatically locked. |
Link to reproduction
npx create-payload-app
Describe the Bug
A blank template is unable to deploy on cloud. It appears to be caused by a dependency deep in the chain being ESM-only.
Other dependencies appear to be having the same issue:
Possible Solutions
Cloud deployments for the template were working previously, determine what dep was updated to cause this - revert it.
Our direct dependency is
resend
. See if updating that dependency fixes the referenceAdd a
resolutions
to the package.json. Not the best solution.To Reproduce
npx create-payload-app -t blank
Payload Version
2.1.1
Adapters and Plugins
No response
The text was updated successfully, but these errors were encountered: