Skip to content

Commit

Permalink
Allow minify options for plugins disabled by default (#823)
Browse files Browse the repository at this point in the history
  • Loading branch information
nemophrost authored and boopathi committed May 1, 2018
1 parent 5527669 commit 7b17646
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/babel-preset-minify/src/index.js
Expand Up @@ -66,6 +66,8 @@ function preset(context, _opts = {}) {
// handle plugins and their options
for (const [name] of PLUGINS) {
if (isPlainObject(opts[name])) {
// for plugins disabled by default
pluginsMap[name].enabled = true;
pluginsMap[name].options = opts[name];
} else if (opts[name] !== void 0) {
pluginsMap[name].enabled = !!opts[name];
Expand Down

0 comments on commit 7b17646

Please sign in to comment.