Update npm dependencies
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone Build is passing

This commit is contained in:
Alex Page 2022-11-28 17:19:16 -05:00
parent a7d7d219a8
commit 67822f9f31
3 changed files with 2600 additions and 4215 deletions

6757
package-lock.json generated

File diff suppressed because it is too large Load diff

View file

@ -4,15 +4,15 @@
"version": "0.1.0", "version": "0.1.0",
"scripts": { "scripts": {
"build": "rimraf dist pkg && webpack", "build": "rimraf dist pkg && webpack",
"start": "rimraf dist pkg && webpack-dev-server --open -d", "start": "rimraf dist pkg && webpack-dev-server --open",
"test": "cargo test && wasm-pack test --headless" "test": "cargo test && wasm-pack test --headless"
}, },
"devDependencies": { "devDependencies": {
"@wasm-tool/wasm-pack-plugin": "^1.1.0", "@wasm-tool/wasm-pack-plugin": "^1.1.0",
"copy-webpack-plugin": "^5.0.3", "copy-webpack-plugin": "^11.0.0",
"webpack": "^4.42.0", "rimraf": "^3.0.0",
"webpack-cli": "^3.3.3", "webpack": "^5.75.0",
"webpack-dev-server": "^3.7.1", "webpack-cli": "^5.0.0",
"rimraf": "^3.0.0" "webpack-dev-server": "^4.11.1"
} }
} }

View file

@ -5,24 +5,32 @@ const WasmPackPlugin = require("@wasm-tool/wasm-pack-plugin");
const dist = path.resolve(__dirname, "dist"); const dist = path.resolve(__dirname, "dist");
module.exports = { module.exports = {
mode: "production", mode: "production",
entry: { entry: {
index: "./js/index.js" index: "./js/index.js"
}, },
output: { output: {
path: dist, path: dist,
filename: "[name].js" filename: "[name].js"
}, },
devServer: { experiments: {
contentBase: dist, asyncWebAssembly: true,
}, syncWebAssembly: true
plugins: [ },
new CopyPlugin([ devServer: {
path.resolve(__dirname, "static") static: {
]), directory: dist,
}
},
plugins: [
new CopyPlugin({
patterns: [
"static"
]
}),
new WasmPackPlugin({ new WasmPackPlugin({
crateDirectory: __dirname, crateDirectory: __dirname,
}), }),
] ]
}; };