Skip to content

Commit 01990d0

Browse files
pi0yyx990803
authored andcommitted
fix(templateLoder): honor options.productionMode (#1409)
1 parent bb8a85b commit 01990d0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: lib/loaders/templateLoader.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ module.exports = function (source) {
1515
const options = loaderUtils.getOptions(loaderContext) || {}
1616
const { id } = query
1717
const isServer = loaderContext.target === 'node'
18-
const isProduction = loaderContext.minimize || process.env.NODE_ENV === 'production'
18+
const isProduction = options.productionMode || loaderContext.minimize || process.env.NODE_ENV === 'production'
1919
const isFunctional = query.functional
2020

2121
// allow using custom compiler via options

0 commit comments

Comments
 (0)