wallet-core/node_modules/es6-error/babel-config.js

32 lines
490 B
JavaScript
Raw Normal View History

2017-05-28 00:38:50 +02:00
'use strict';
var plugins = [
[
"babel-plugin-transform-builtin-extend",
{
"globals": ["Error"],
"approximate": true
}
]
];
var env = process.env.BABEL_ENV || process.env.NODE_ENV;
var modules;
if (env === 'es') {
modules = false;
} else if (env === 'ts') {
modules = 'commonjs';
} else {
modules = 'commonjs';
plugins.push('add-module-exports');
}
module.exports = {
"presets": [
["es2015", { modules: modules }]
],
"plugins": plugins
};