Description
Version
15.4.1
Reproduction link
https://github.com/NetMatch/vue-loader-testcase
Steps to reproduce
- Clone the linked repository
- Execute
npm ci
- Execute
npm run build
- Inspect the generated source maps in the
dist
folder
What is expected?
vue-loader
generates source maps for the source Vue SFC file and the constituent template, style and script sections.
The appendExtension
option is honored and the source map lists the constituents as Example.vue.html
, Example.vue.css
and Example.vue.js
.
What is actually happening?
vue-loader
generates source maps for intermediate stages of generated JS code rather than the original sources of the template, style and JS sections.
The appendExtension
option is not honored. All generated files are generated under the Example.vue
name and are disambiguated by adding part of their content hash as a suffixed query string.
Same issue as in #1163 where the root cause was claimed to be Babel and should have been resolved with latest versions of all build tools. However, the test case presented here uses the latest versions of Webpack and vue-loader and doesn't even use Babel at all. And still has this problem.