Closed valentinMERCIER closed 1 year ago
I have same problem, can anyone help?
(node:5125) Warning: To load an ES module, set "type": "module" in the package.json or use the .mjs extension.
(Use node --trace-warnings ... to show where the warning was created)
ERROR [worker reload] [worker init] Unexpected token 'export' 11:14:30
export default {
^^^^^^
SyntaxError: Unexpected token 'export'
at wrapSafe (internal/modules/cjs/loader.js:984:16)
at Module._compile (internal/modules/cjs/loader.js:1032:27)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1097:10)
at Module.load (internal/modules/cjs/loader.js:933:32)
at Function.Module._load (internal/modules/cjs/loader.js:774:14)
at ModuleWrap.<anonymous> (internal/modules/esm/translators.js:199:29)
at ModuleJob.run (internal/modules/esm/module_job.js:152:23)
at async Loader.import (internal/modules/esm/loader.js:177:24)
at async Object.loadESM (internal/process/esm_loader.js:68:5)
same problem
(node:7806) Warning: To load an ES module, set "type": "module" in the package.json or use the .mjs extension. (Use
node --trace-warnings ...` to show where the warning was created)
ERROR [worker reload] [worker init] Unexpected token 'export' 11:05:03
export default { ^^^^^^
SyntaxError: Unexpected token 'export'
at Object.compileFunction (node:vm:352:18)
at wrapSafe (node:internal/modules/cjs/loader:1032:15)
at Module._compile (node:internal/modules/cjs/loader:1067:27)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1155:10)
at Module.load (node:internal/modules/cjs/loader:981:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
at ModuleWrap.
Setting type
to module
does work, but it brings another issue.
You are using a plugin with legacy Nuxt 2 format (context, inject) which is likely to be broken.
In future they will be ignored so this module will need updating for this.
Should be fixed.
I have an issue when trying nuxt-mail with nuxt3
I've ran
yarn add nuxt-mail
and then add the following config to my nuxt.config.ts file
I then encounter the following error
Anyone has encountered that error ?