MCPcopy Create free account
hub / github.com/cobish/cobish.github.io / copyAndDelFiles

Function copyAndDelFiles

webpack.config.js:64–85  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

62
63// 复制和删除文件
64function copyAndDelFiles() {
65 var copyFile = '';
66
67 // 复制文件
68 if (isDev()) {
69 copyFile = 'src/html/index_dev.html';
70 }
71
72 if (isProd()) {
73 copyFile = 'src/html/index.html';
74 }
75
76 copy(copyFile, 'index.html', function(error) {
77 if (error) {
78 return console.error(error);
79 }
80 });
81
82 if (isProd()) {
83 del(['dist']);
84 }
85}
86
87// 获取配置
88function getPlugins() {

Callers 1

webpack.config.jsFile · 0.85

Calls 2

isDevFunction · 0.85
isProdFunction · 0.85

Tested by

no test coverage detected