hsiangfeng / hsiangfeng.github.io

是 Ray 不是 Array - Ray Blog
https://israynotarray.com/
7 stars 0 forks source link

webpack/20210228/2274885256/ #11

Open utterances-bot opened 2 years ago

utterances-bot commented 2 years ago

Webpack 5 走起! - plugins(4) - clean-webpack-plugin | 是 Ray 不是 Array

接下來這一篇將會介紹另一個插件,是關於清除檔案的插件。

https://israynotarray.com/webpack/20210228/2274885256/

qulingyuan commented 2 years ago

写的非常清晰!不过webpack5清除档案也可以使用 output.clean 选项: output: { path: path.resolve(__dirname, './dist'), filename: '[name].[contenthash:6].bundle.js',

hsiangfeng commented 2 years ago

写的非常清晰!不过webpack5清除档案也可以使用 output.clean 选项: output: { path: path.resolve(__dirname, './dist'), filename: '[name].[contenthash:6].bundle.js',

* clean: true
  }

謝謝熱心提供方式 :D