From 3110a65cdd633d2713fbbd2dd541506bb45ab1b2 Mon Sep 17 00:00:00 2001 From: Brian Ng Date: Tue, 11 Apr 2017 21:24:26 -0500 Subject: [PATCH 1/2] Add a reminder about include/exclude options [skip ci] --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 02d47d5d..eca1a09b 100644 --- a/README.md +++ b/README.md @@ -170,6 +170,8 @@ This option is useful if there is a bug in a native implementation, or a combina For example, Node 4 supports native classes but not spread. If `super` is used with a spread argument, then the `transform-es2015-classes` transform needs to be `include`d, as it is not possible to transpile a spread with `super` otherwise. +> NOTE: The `include` and `exclude` options _only_ work with the [plugins included with this preset](https://github.com/babel/babel-preset-env/blob/master/data/plugin-features.js); so, for example, including `transform-do-expressions` or excluding `transform-function-bind` will throw errors. + ### `exclude` `Array`, defaults to `[]`. From 766ef5a81ac3ee079bdee367cc79b8cab76cc803 Mon Sep 17 00:00:00 2001 From: Brian Ng Date: Wed, 12 Apr 2017 07:50:23 -0500 Subject: [PATCH 2/2] include note about adding plugin [skip ci] --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index eca1a09b..6068bc0d 100644 --- a/README.md +++ b/README.md @@ -170,7 +170,7 @@ This option is useful if there is a bug in a native implementation, or a combina For example, Node 4 supports native classes but not spread. If `super` is used with a spread argument, then the `transform-es2015-classes` transform needs to be `include`d, as it is not possible to transpile a spread with `super` otherwise. -> NOTE: The `include` and `exclude` options _only_ work with the [plugins included with this preset](https://github.com/babel/babel-preset-env/blob/master/data/plugin-features.js); so, for example, including `transform-do-expressions` or excluding `transform-function-bind` will throw errors. +> NOTE: The `include` and `exclude` options _only_ work with the [plugins included with this preset](https://github.com/babel/babel-preset-env/blob/master/data/plugin-features.js); so, for example, including `transform-do-expressions` or excluding `transform-function-bind` will throw errors. To use a plugin _not_ included with this preset, add them to your [config](https://babeljs.io/docs/usage/babelrc/) directly. ### `exclude`