Simplify webpack config

This commit is contained in:
Surma
2018-05-21 13:29:24 +01:00
parent e38e7154a6
commit d4a616713a

View File

@ -48,18 +48,6 @@ module.exports = function (_, env) {
}
},
module: {
// This is needed to make webpack NOT process wasm files.
// See https://github.com/webpack/webpack/issues/6725
defaultRules: [
{
type: "javascript/auto",
resolve: {}
},
{
test: /\.json$/i,
type: "json"
},
],
rules: [
{
test: /\.(scss|sass)$/,
@ -127,12 +115,14 @@ module.exports = function (_, env) {
},
{
test: /\/codecs\/.*\.wasm$/,
// This is needed to make webpack NOT process wasm files.
// See https://github.com/webpack/webpack/issues/6725
type: 'javascript/auto',
loader: 'file-loader',
}
]
],
},
plugins: [
// Ignore some of the native Node modules for any of the codecs. These files are generated by Emscripten and are supposed to also work in Node, which we dont care about.
new webpack.IgnorePlugin(/(fs)/, /\/codecs\//),
// Pretty progressbar showing build progress:
new ProgressBarPlugin({