-
Notifications
You must be signed in to change notification settings - Fork 2
/
vue.config.js
46 lines (45 loc) · 1.42 KB
/
vue.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
const { defineConfig } = require("@vue/cli-service");
const HtmlWebpackPlugin = require("html-webpack-plugin");
module.exports = defineConfig({
transpileDependencies: true,
pluginOptions: {
electronBuilder: {
mainProcessWatch: ["src/electron-service/*/*"], //手动配置监听文件
nodeIntegration: true,
chainWebpackMainProcess: (config) => {
config.output.filename("background.js");
},
builderOptions: {
productName: "打印组件",
appId: "com.qhys",
copyright: "QHYS",
win: {
icon: "public/favicon.png", //图标路径
artifactName: "print.${ext}",
target: [
{
target: "nsis", //利用nsis制作安装程序
// target: 'portable', //单文件免安装版
arch: [
"x64", //64位
// "ia32" //32位
],
},
],
},
nsis: {
oneClick: false, // 是否一键安装
allowToChangeInstallationDirectory: true, // 是否允许修改安装目录
allowElevation: true, // 允许请求提升。 如果为false, 则用户必须使用提升的权限重新启动安装程序。
},
publish: [
{
provider: "generic",
url: `${process.env.VUE_APP_FEED_URL}/printComponents/`,
},
],
},
},
},
lintOnSave: false,
});