electron 控制台 警告
security-warnings.ts:165 Electron Security Warning (Disabled webSecurity) This renderer process has "webSecurity" disabled. Thisexposes users of this app to severe security risks.For more information
security-warnings.ts:165 Electron Security Warning (Disabled webSecurity) This renderer process has "webSecurity" disabled. This
exposes users of this app to severe security risks.For more information and help, consult
https://electronjs.org/docs/tutorial/security.
This warning will not show up
once the app is packaged.
warnAboutDisabledWebSecurity @ security-warnings.ts:165
logSecurityWarnings @ security-warnings.ts:292
loadHandler @ security-warnings.ts:314
security-warnings.ts:200 Electron Security Warning (allowRunningInsecureContent) This renderer process has "allowRunningInsecureContent"
enabled. This exposes users of this app to severe security risks.
For more information and help, consult
https://electronjs.org/docs/tutorial/security.
This warning will not show up
once the app is packaged.
warnAboutInsecureContentAllowed @ security-warnings.ts:200
logSecurityWarnings @ security-warnings.ts:294
loadHandler @ security-warnings.ts:314
security-warnings.ts:182 Electron Security Warning (Insecure Content-Security-Policy) This renderer process has either no Content Security
Policy set or a policy with "unsafe-eval" enabled. This exposes users of
this app to unnecessary security risks.For more information and help, consult
https://electronjs.org/docs/tutorial/security.
This warning will not show up
once the app is packaged.

需要在 main.js 文件中 加如下代码
process.env['ELECTRON_DISABLE_SECURITY_WARNINGS'] = 'true'
更多推荐


所有评论(0)