How can I stop printing webpack assets while testing in nuxtjs? I am using ava
. I tried to set webpack stats in nuxt.config but it is not working:
// Does not work
{
...
build: {
...
extend (config, { isClient }) {
...
if (process.env.NODE_ENV === 'test') {
config.stats = 'errors-only'
}
}
}
...
}
What am I trying to do is to stop showing logs like this from Webpack:
Hash: 5a2a3d23f88174970ed8
Version: webpack 3.12.0
Time: 22209ms
Asset Size Chunks Chunk Names
pages/widgets/index.51838abe9967a9e0b5ff.js 1.17 kB 10 [emitted] pages/widgets/index
img/icomoon.7f1da5a.svg 5.38 kB [emitted]
fonts/icomoon.2d429d6.ttf 2.41 kB [emitted]
img/fontawesome-webfont.912ec66.svg 444 kB [emitted] [big]
fonts/fontawesome-webfont.b06871f.ttf 166 kB [emitted]
img/mobile.8891a7c.png 39.6 kB [emitted]
img/play_button.6b15900.png 14.8 kB [emitted]
img/keyword-back.f95e10a.jpg 43.4 kB [emitted]
fonts/icomoon.16db67c.woff 2.49 kB [emitted]
fonts/icomoon.2fcbf50.eot 2.58 kB [emitted]
fonts/fontawesome-webfont.674f50d.eot 166 kB [emitted]
fonts/fontawesome-webfont.fee66e7.woff 98 kB [emitted]
Aucun commentaire:
Enregistrer un commentaire