We have been using @akebifiky/remark-simple-plantuml for a while. It used to work until nuxt v3.6.5. After upgrading nuxt to a newer version nuxt build breaks with the error RollupError: Expected 'from', got '@'.
Running npm run dev works still just fine.
Additional context
No response
Logs
> npm run build
...
ℹ Initializing prerenderer nitro 9:16:44 AM
[9:16:46 AM] WARN (inject plugin) rollup-plugin-inject: failed to parse /home/projects/github-yghvz1/.nuxt/mdc-imports.mjs. Consider restricting the plugin to particular files via options.include
ERROR RollupError: Expected 'from', got '@' (Note that you need plugins to import files that are not JavaScript) nitro 9:16:46 AM
1: import @akebifikyRemarkSimplePlantuml from '@akebifiky/remark-simple-plantuml'
^
2:
3: export const remarkPlugins = {
ERROR Expected 'from', got '@' (Note that you need plugins to import files that are not JavaScript) 9:16:46 AM
at error (node_modules/rollup/dist/es/shared/parseAst.js:468:30)
at parseError (node_modules/rollup/dist/es/shared/parseAst.js:1103:9)
at convertNode (node_modules/rollup/dist/es/shared/parseAst.js:2188:12)
at convertProgram (node_modules/rollup/dist/es/shared/parseAst.js:1096:12)
at Module.parseAstAsync (node_modules/rollup/dist/es/shared/parseAst.js:2239:12)
at async Module.tryParseAsync (node_modules/rollup/dist/es/shared/node-entry.js:13564:20)
at async Module.setSource (node_modules/rollup/dist/es/shared/node-entry.js:13145:35)
at async ModuleLoader.addModuleSource (node_modules/rollup/dist/es/shared/node-entry.js:17835:13)
ERROR Expected 'from', got '@' (Note that you need plugins to import files that are not JavaScript)
Environment
package.json
nuxt.config.ts
Reproduction
https://stackblitz.com/edit/github-yghvz1?file=package.json
Run
npm run build
and see error in console.Describe the bug
We have been using
@akebifiky/remark-simple-plantuml
for a while. It used to work until nuxt v3.6.5. After upgrading nuxt to a newer versionnuxt build
breaks with the errorRollupError: Expected 'from', got '@'
.Running
npm run dev
works still just fine.Additional context
No response
Logs