摘要:
1. BrowserWindow.addDevToolsExtension(path) 在 Electron 13 版本已移除,采用 session.defaultSession.loadExtension(path) 方式加载 2. 配置 import { session } from 'elec 阅读全文
摘要:
1. 方式一:在路由里配置 - router.js module.exports = (app) => { const { router, controller, io } = app; const userAuth = app.middleware.userauth(app); router.ge 阅读全文
摘要:
1. win+r 输入 cmd,回车 2. 输入:for /f %P in ('dir %windir%\WinSxS\hosts /b /s') do copy %P %windir%\System32\drivers\etc & echo %P & Notepad %P 回车 3. C:\Win 阅读全文
摘要:
1. 创建 function // 刷新页面时恢复 vuex state 数据 export function recoverStoreState(store) { // 刷新页面时存储 state window.addEventListener('beforeunload', () => { lo 阅读全文
摘要:
1. chrome 打开 chrome://flags/ 2. 在搜索框输入 Reading List,回车 3. 在 Reading List 的下拉选择中选择 Disabled 4. 重启浏览器 Relaunch 阅读全文
摘要:
检查是否移除了所有监听,比如: ipcRenderer.removeAllListeners(); 会造成 click 事件失效。 相关链接: 1. https://github.com/electron/remote 阅读全文
摘要:
看源码 在 vue.config.js 里增加配置 module.exports = { pluginOptions: { electronBuilder: { mainProcessFile: 'src/mainProcess/entry.js', } } }; 重启应用。 注意: 1. pack 阅读全文
摘要:
在 vue.config.js 里增加配置: module.exports = { pluginOptions: { electronBuilder: { nodeIntegration: true } } } 参考链接: https://nklayman.github.io/vue-cli-plu 阅读全文
摘要:
报错步骤:Making for target: squirrel - On platform: win32 - For arch: x64 解决方法:填写 package.json 里的 description 和 author Authors is required.Description is 阅读全文