R
R
resibe2021-11-22 02:34:07
webpack
resibe, 2021-11-22 02:34:07

How can I view webpack default settings from vue/cli?

Hello, trying to learn how to optimize the site as much as possible (out of curiosity), I often remove the default webpack settings and change them to my own, finding examples of documentation, for example like this

chainWebpack: (config) => {
    config.plugins.delete("html");
    config.plugins.delete("preload");
    config.plugins.delete("prefetch");
    config.optimization.delete("splitChunks");
  },

However, I faced the problem of lack of documentation and slow search for information, I would like to see which plugins are configured out of the box (get a list of html, preload, prefetch ...), parsing vue sources from github is not very fast and efficient,
doing it from vsCode is faster using
"Go to definition", "Go to type implementations", "Go to refrences"
but they only go to the delete function for example, but how do I get to the plugins themselves...

Answer the question

In order to leave comments, you need to log in

1 answer(s)
R
resibe, 2021-11-22
@resibe

In general, you can use yarn vue-cli-service inspect either vue inspector

//package.json
  "scripts": {
    "inspect": "vue-cli-service inspect > current-webpack-settings.txt"
}
andyarn inspect

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question