mirror of
https://github.com/flarum/framework.git
synced 2025-02-21 16:07:23 +08:00
Optimize babel config to reduce output filesize
This commit is contained in:
parent
eb9756a39e
commit
14825b58a7
@ -27,9 +27,12 @@ module.exports = function(options = {}) {
|
||||
use: {
|
||||
loader: 'babel-loader',
|
||||
options: {
|
||||
presets: ['@babel/preset-env', '@babel/preset-react'],
|
||||
presets: [
|
||||
['@babel/preset-env', {modules: false, loose: true}],
|
||||
['@babel/preset-react']
|
||||
],
|
||||
plugins: [
|
||||
['@babel/plugin-transform-runtime'],
|
||||
['@babel/plugin-transform-runtime', {useESModules: true}],
|
||||
['@babel/plugin-proposal-class-properties'],
|
||||
['@babel/plugin-transform-react-jsx', {pragma: 'm'}]
|
||||
]
|
||||
|
Loading…
x
Reference in New Issue
Block a user