mirror of
https://github.com/zhigang1992/react.git
synced 2026-04-24 04:15:54 +08:00
build: supprot esm bundle
chore: ignore esm folder
This commit is contained in:
19
scripts/babel.config.js
Normal file
19
scripts/babel.config.js
Normal file
@@ -0,0 +1,19 @@
|
||||
module.exports = {
|
||||
presets: [
|
||||
[
|
||||
'@babel/preset-env',
|
||||
{
|
||||
bugfixes: true,
|
||||
modules: false,
|
||||
},
|
||||
],
|
||||
'@babel/preset-react',
|
||||
'@babel/preset-typescript',
|
||||
],
|
||||
plugins: [
|
||||
'styled-jsx/babel',
|
||||
['@babel/plugin-proposal-object-rest-spread', { loose: true }],
|
||||
['@babel/plugin-transform-runtime', { useESModules: true }],
|
||||
],
|
||||
ignore: [/@babel[\\|/]runtime/],
|
||||
}
|
||||
Reference in New Issue
Block a user