Vue-cli: Cannot fully override rule in Webpack config

Created on 23 Mar 2018  路  5Comments  路  Source: vuejs/vue-cli

Version

3.0.0-beta.6

Reproduction link

https://codesandbox.io/s/7mklr625z6

Steps to reproduce

Go to App.vue to see the loading of the SVG asset. The SVG contents is displayed in the view.

What is expected?

svg-sprite-loader is not being used (setup in vue.config.js). The Star data property should be an object after being processed by this loader.

What is actually happening?

The SVG is still being processed with file-loader from the default Webpack configuration and is therefore returning a string.

Most helpful comment

Hi @yyx990803 ,

Created a repo for reproduction.
https://github.com/divyamrastogi/config-override-bug-demo
I'm facing this same issue while trying to change the loader for svg files, the default loader (file-loader) doesn't get overridden.
Hope you're able to reproduce and reopen this issue. Let me know if you need more information.
Thanks!

All 5 comments

CodeSandbox is not using the latest CLI version yet, so this is not a valid reproduction.

I鈥檓 not sure then how I would demo a reproduction? The result is the same as what I see on latest anyway. Unsure if it鈥檚 a bug then.

You can provide a GitHub repository as a reproduction, but make sure to keep it minimal.

Hi @yyx990803 ,

Created a repo for reproduction.
https://github.com/divyamrastogi/config-override-bug-demo
I'm facing this same issue while trying to change the loader for svg files, the default loader (file-loader) doesn't get overridden.
Hope you're able to reproduce and reopen this issue. Let me know if you need more information.
Thanks!

Hi @yyx990803 - is it possible to get this issue reopened at all in light of the above repo? Thanks.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

JIANGYUJING1995 picture JIANGYUJING1995  路  3Comments

DrSensor picture DrSensor  路  3Comments

wahidrahim picture wahidrahim  路  3Comments

BusyHe picture BusyHe  路  3Comments

chasegiunta picture chasegiunta  路  3Comments