iapyang
5 years ago
7 changed files with 90 additions and 25 deletions
@ -0,0 +1,34 @@
|
||||
module.exports = function (api) { |
||||
api.cache(true); |
||||
const presets = [ |
||||
[ |
||||
"@babel/preset-env", |
||||
{ |
||||
targets: { |
||||
ie: 8, |
||||
}, |
||||
}, |
||||
], |
||||
"@babel/preset-typescript", |
||||
]; |
||||
const plugins = [ |
||||
[ |
||||
"@babel/plugin-proposal-decorators", |
||||
{ |
||||
legacy: true, |
||||
}, |
||||
], |
||||
"@babel/plugin-proposal-class-properties", |
||||
"@babel/plugin-transform-block-scoping", |
||||
["@babel/plugin-transform-classes", { |
||||
loose: true, |
||||
}], |
||||
"@babel/plugin-transform-proto-to-assign", |
||||
"@babel/plugin-transform-modules-commonjs", |
||||
]; |
||||
|
||||
return { |
||||
presets, |
||||
plugins, |
||||
}; |
||||
}; |
Loading…
Reference in new issue