diff --git a/packages/web/index.js b/packages/web/index.js index 610416e64..777854f61 100644 --- a/packages/web/index.js +++ b/packages/web/index.js @@ -95,9 +95,6 @@ module.exports = (neutrino, opts = {}) => { exclude: [staticDir], babel: options.babel }); - neutrino.use(clean, { - paths: [neutrino.options.output] - }); neutrino.config .target('web') @@ -162,6 +159,7 @@ module.exports = (neutrino, opts = {}) => { .use(optimize.ModuleConcatenationPlugin); }) .when(neutrino.options.command === 'build', (config) => { + neutrino.use(clean, { paths: [neutrino.options.output] }); neutrino.use(copy, { patterns: [{ context: staticDir,