Created
October 8, 2018 14:42
-
-
Save mustmodify/e5bf8756990aae8cc28983b0ba681bc2 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const config = { | |
entry: [ | |
'es5-shim/es5-shim', | |
'es5-shim/es5-sham', | |
'babel-polyfill', | |
'./app/bundles/SAW/startup/registration', | |
], | |
output: { | |
filename: 'webpack-bundle.js', | |
path: pathLib.resolve(__dirname, '../app/assets/webpack'), | |
}, | |
resolve: { | |
extensions: ['.js', '.jsx'], | |
alias: { | |
Reducers: path.resolve(__dirname, 'app/bundles/SAW/reducers') | |
} | |
}, | |
plugins: [ | |
new webpack.EnvironmentPlugin({ NODE_ENV: 'development' }), | |
], | |
module: { | |
rules: [ | |
{ | |
test: require.resolve('react'), | |
use: { | |
loader: 'imports-loader', | |
options: { | |
shim: 'es5-shim/es5-shim', | |
sham: 'es5-shim/es5-sham', | |
} | |
}, | |
}, | |
{ | |
test: /\.jsx?$/, | |
use: 'babel-loader', | |
exclude: /node_modules/, | |
}, | |
], | |
}, | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment