diff --git a/.babelrc b/.babelrc index e68d2fea..d2579367 100644 --- a/.babelrc +++ b/.babelrc @@ -1,3 +1,21 @@ { - "presets": ["es2015", "stage-2", "react"] + "presets": ["react"], + "env": { + "commonjs": { + "plugins": [ + "transform-class-properties", + "transform-object-rest-spread" + ], + "presets": ["env"] + }, + "es": { + "plugins": [ + "transform-class-properties", + "transform-object-rest-spread" + ], + "presets": [ + ["env", { "modules": false }] + ] + } + }, }