'use strict';

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports['default'] = babel;

var _os = require('os');

var _context = require('../bin/common/context');

var _context2 = _interopRequireDefault(_context);

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }

function babel(mode, env) {
  var choerodonConfig = _context2['default'].choerodonConfig;

  return choerodonConfig.babelConfig({
    presets: ['react', ['es2015'], 'stage-1'],
    plugins: ['transform-async-to-generator', 'transform-decorators-legacy', 'transform-class-properties', 'transform-runtime', 'lodash', ['import', [{
      libraryName: 'choerodon-ui',
      style: true
    }, {
      libraryName: 'choerodon-hap-ui',
      style: true
    }]]]
  }, mode, env);
}