Skip to content

Commit

Permalink
More webpack joy
Browse files Browse the repository at this point in the history
  • Loading branch information
simoncozens committed Dec 9, 2024
1 parent 08bbb4b commit 48cd1b5
Showing 1 changed file with 8 additions and 9 deletions.
17 changes: 8 additions & 9 deletions shaperglot-web/www/webpack.config.js
Original file line number Diff line number Diff line change
@@ -1,24 +1,23 @@
const CopyWebpackPlugin = require("copy-webpack-plugin");
const path = require('path');
const path = require("path");
const crypto = require("crypto");
const crypto_orig_createHash = crypto.createHash;
crypto.createHash = algorithm => crypto_orig_createHash(algorithm == "md4" ? "sha256" : algorithm);
crypto.createHash = (algorithm) =>
crypto_orig_createHash(algorithm == "md4" ? "sha256" : algorithm);

module.exports = {
entry: "./bootstrap.js",
experiments: {
asyncWebAssembly: true
asyncWebAssembly: true,
},
output: {
path: path.resolve(__dirname, "..", "..", "docs"),
filename: "bootstrap.js"
filename: "bootstrap.js",
},
mode: "development",
plugins: [
new CopyWebpackPlugin([
{ "patterns": 'index.html' },
{ "patterns": '*.css' },
]
)
new CopyWebpackPlugin({
patterns: [{ from: "index.html" }, { from: "*.css" }],
}),
],
};

0 comments on commit 48cd1b5

Please sign in to comment.