Open bartlomieju opened 11 months ago
is this a problem that needs to be fixed on Denos end? (Still new to open source, just trying to understand how it could be fixed)
I disagree that this is a bug. The file is not located in an npm package. It's located at file:///Users/ib/dev/next-app/next.config.js
, which means it is ESM. This can be fixed in next.config.js by changing:
module.exports = nextConfig;
To...
export default nextConfig;
...as Next.js loads this file via a dynamic import. We should update the error message to explain that module.exports =
needs to be converted to ESM.
Chaging
module.exports =
toexport default
fixes the problem.