Files
pqs-9100_client/electron/config/config.default.js

72 lines
2.0 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

'use strict';
const path = require('path');
const {getBaseDir} = require('ee-core/ps');
/**
* 默认配置
*/
module.exports = () => {
return {
openDevTools: false,
singleLock: true,
windowsOption: {
title: 'NPQS9100-自动检测平台',
menuBarVisible: false,
width: 1920,
height: 1000,
minWidth: 1024,
minHeight: 640,
webPreferences: {
//webSecurity: false,
contextIsolation: false, // false -> 可在渲染进程中使用electron的apitrue->需要bridge.js(contextBridge)
nodeIntegration: true,
//preload: path.join(getElectronDir(), 'preload', 'bridge.js'),
},
frame: true,
show: true,
icon: path.join(getBaseDir(), 'public', 'images', 'logo-32.png'),
},
logger: {
level: 'INFO',
outputJSON: false,
appLogName: '9100.log',
coreLogName: '9100-core.log',
errorLogName: '9100-error.log'
},
// 远程web地址
remote: {
enable: false,
url: ''
},
socketServer: {
enable: false,
port: 7070,
path: "/socket.io/",
connectTimeout: 45000,
pingTimeout: 30000,
pingInterval: 25000,
maxHttpBufferSize: 1e8,
transports: ["polling", "websocket"],
cors: {
origin: true,
},
channel: 'socket-channel'
},
httpServer: {
enable: false,
https: {
enable: false,
key: '/public/ssl/localhost+1.key',
cert: '/public/ssl/localhost+1.pem'
},
host: '127.0.0.1',
port: 7071,
},
mainServer: {
indexPath: '/public/dist/index.html',
channelSeparator: '/',
}
}
}