From fe6ad6e4a194b24fb6e8f7265a19a608d792b194 Mon Sep 17 00:00:00 2001 From: Pooya Parsa Date: Fri, 28 Sep 2018 13:20:44 +0330 Subject: [PATCH] fix(templateLoder): honor options.productionMode --- lib/loaders/templateLoader.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/loaders/templateLoader.js b/lib/loaders/templateLoader.js index d5b187415..8db2618b6 100644 --- a/lib/loaders/templateLoader.js +++ b/lib/loaders/templateLoader.js @@ -15,7 +15,7 @@ module.exports = function (source) { const options = loaderUtils.getOptions(loaderContext) || {} const { id } = query const isServer = loaderContext.target === 'node' - const isProduction = loaderContext.minimize || process.env.NODE_ENV === 'production' + const isProduction = options.productionMode || loaderContext.minimize || process.env.NODE_ENV === 'production' const isFunctional = query.functional // allow using custom compiler via options