27 lines
702 B
JavaScript
27 lines
702 B
JavaScript
const path = require("path");
|
|
const WasmPackPlugin = require("@wasm-tool/wasm-pack-plugin");
|
|
const OptimizeWasmPlugin = require("optimize-wasm-webpack-plugin");
|
|
|
|
module.exports = {
|
|
lintOnSave: false,
|
|
configureWebpack: {
|
|
optimization: {
|
|
minimizer: [new OptimizeWasmPlugin()]
|
|
},
|
|
plugins: [
|
|
new WasmPackPlugin({
|
|
crateDirectory: path.resolve(__dirname, "crate")
|
|
})
|
|
]
|
|
},
|
|
pluginOptions: {
|
|
electronBuilder: {
|
|
builderOptions: {
|
|
// TODO electron-builder config https://www.electron.build/configuration/configuration
|
|
appId: "com.crimata.messenger",
|
|
name: "CrimataMessenger"
|
|
},
|
|
preload: "src/preload.ts"
|
|
}
|
|
}
|
|
};
|