This PR migrates the babel configuration to babel-preset-env, which automatically picks the preset to transpile the code based on the target environment.
Since we use Electron 1.8 which internally runs Node 7.x, I enabled the useBuiltIns: true option to polyfill even less since a lot of modern JavaScript features are supported natively.
transform-object-rest-spread is needed because there were some issues in Babel 6 parser, however we'll be able to drop it once upgraded to the next stable Babel. It's just that each time I look at Babel, it remains in beta and I'd like things to settle before upgrading to the latest.
This PR migrates the babel configuration to
babel-preset-env
, which automatically picks the preset to transpile the code based on the target environment.Since we use Electron 1.8 which internally runs Node 7.x, I enabled the
useBuiltIns: true
option to polyfill even less since a lot of modern JavaScript features are supported natively.transform-object-rest-spread
is needed because there were some issues in Babel 6 parser, however we'll be able to drop it once upgraded to the next stable Babel. It's just that each time I look at Babel, it remains in beta and I'd like things to settle before upgrading to the latest.