From 65d5fcd91caf4923ff32f2d3b8bc12b53790e3d6 Mon Sep 17 00:00:00 2001 From: EGOIST <0x142857@gmail.com> Date: Wed, 6 Dec 2017 10:56:29 +0800 Subject: [PATCH] Fix: only use TimeFixPlugin in dev mode --- lib/builder/webpack/base.config.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/builder/webpack/base.config.js b/lib/builder/webpack/base.config.js index 5188e92063..4de888f20b 100644 --- a/lib/builder/webpack/base.config.js +++ b/lib/builder/webpack/base.config.js @@ -106,7 +106,9 @@ export default function webpackBaseConfig(name) { } // Add timefix-plugin before others plugins - config.plugins.unshift(new TimeFixPlugin()) + if (this.options.dev) { + config.plugins.unshift(new TimeFixPlugin()) + } // CSS extraction const extractCSS = this.options.build.extractCSS