front
This commit is contained in:
32
frontend-react/babel.config.js
Normal file
32
frontend-react/babel.config.js
Normal file
@@ -0,0 +1,32 @@
|
||||
module.exports = {
|
||||
presets: [
|
||||
[
|
||||
'@babel/preset-env',
|
||||
{
|
||||
modules: false
|
||||
}
|
||||
],
|
||||
'@babel/preset-react'
|
||||
],
|
||||
plugins: [
|
||||
'@babel/plugin-transform-runtime',
|
||||
'@babel/plugin-syntax-dynamic-import',
|
||||
//"@babel/plugin-proposal-class-properties"
|
||||
['@babel/plugin-proposal-class-properties', { loose: false }] // cf. https://mobx.js.org/installation.html
|
||||
],
|
||||
env: {
|
||||
production: {
|
||||
only: ['src'],
|
||||
plugins: [
|
||||
[
|
||||
'transform-react-remove-prop-types',
|
||||
{
|
||||
removeImport: true
|
||||
}
|
||||
],
|
||||
'@babel/plugin-transform-react-inline-elements',
|
||||
'@babel/plugin-transform-react-constant-elements'
|
||||
]
|
||||
}
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user