webpack/examples/wasm-complex/webpack.config.js

24 lines
433 B
JavaScript
Raw Normal View History

2019-05-24 20:24:44 +08:00
module.exports = {
// mode: "development || "production",
output: {
publicPath: "dist/"
},
module: {
rules: [
{
test: /\.wat$/,
use: "wast-loader",
type: "webassembly/async"
2019-05-24 20:24:44 +08:00
}
]
},
optimization: {
chunkIds: "deterministic" // To keep filename consistent between different modes (for example building only)
},
experiments: {
2019-06-05 20:26:08 +08:00
asyncWebAssembly: true,
topLevelAwait: true,
importAwait: true
2019-05-24 20:24:44 +08:00
}
};