nuxt: Nuxt 3, sourcemap points to missing file warning, when using external script files in vue template.
Environment
- Operating System:
Windows_NT - Node Version:
v16.13.2 - Nuxt Version:
3.0.0-rc.3 - Package Manager:
npm@8.3.0 - Builder:
vite - User Config:
privateRuntimeConfig,publicRuntimeConfig,pageTransition,css,app,algolia,components,router,modules,build,vite,hooks,nitro - Runtime Modules:
@vueuse/nuxt@8.6.0,~/modules/sitemap,@nuxtjs/algolia@0.9.2,~/modules/robots,~/modules/staticWebApp - Build Modules:
-
Reproduction
https://stackblitz.com/edit/github-jbyf5k-sa9vua?file=pages%2Findex.vue
Describe the bug
When using external script files it gives an warning pr. import in my solution:
“Sourcemap for “C:/Folder/repo/filepath.page.ts” points to missing source files .”

Is there a confirguration to disable sourcemap for at certain suffix file? I think this is poitning to vite in nuxt.
Additional context
I can see there is a similar issue on react regarding this warning. https://github.com/vitejs/vite/issues/5438
Logs
No response
About this issue
- Original URL
- State: open
- Created 2 years ago
- Reactions: 14
- Comments: 25 (4 by maintainers)
Hey team,
This issue popped up again in v3.1.1. Not sure if it was resolved before. I am using vuetify v3.1.2 with the vite-plugin-vuetify package.
I still have the warning messages after upgrading lockfile and cleaning yarn cache and node_modules.
Present again in stable 3.0.0
Same issue.
Note to self or whoever looks at this first: Issue can be resolved by prefixing with
\0ordep:(https://github.com/vitejs/vite/pull/5587) - but see https://github.com/nuxt/framework/pull/4512 for context - we will need to ensure we’re still transforming virtual modules with other plugins.@horizon188 @VegasChickiChicki @shynline you can use sourcemap: false in nuxt.config
Getting this error after upgrading to Nuxt
3.3.2and login stop workingI tried
but still get warnings
What is even more interesting is that it doesn’t disappear even if I set both to false
I just loaded a normal scss file.
but I can remove warn in this way,
Has this issue been fixed?