随笔分类 -  Electron

Electron学习笔记及问题
摘要:之前版本: import fs from 'fs' fs.readFile(txtFilePath, 'utf-8', function (err, dataText) { console.info("同步文件名In:", basename) //var fileName1 = basename; 阅读全文
posted @ 2022-05-12 17:05 三瑞 阅读(657) 评论(0) 推荐(0) 编辑
摘要:vue报错Error in render: “TypeError: Cannot read property ‘length‘ of undefined“ 原因: el-table 中(列表)属性中有为undefined,所有在列中加一个个v-if判断就可以了 <el-table-column la 阅读全文
posted @ 2022-01-22 12:36 三瑞 阅读(604) 评论(0) 推荐(0) 编辑
摘要:打包 SyntaxError:Cannot use import statement outside a module browser_init.js 安装打包 https://www.jianshu.com/p/d8f3942d5efc "build": { "appId": "com.famil 阅读全文
posted @ 2021-10-09 17:25 三瑞 阅读(592) 评论(0) 推荐(0) 编辑
摘要:安装 cnpm install vue-highlightjs --save main.js import VueHighlightJS from 'vue-highlightjs' import 'highlight.js/styles/atom-one-dark.css' Vue.use(Vue 阅读全文
posted @ 2021-08-27 16:10 三瑞 阅读(272) 评论(0) 推荐(0) 编辑
摘要:Error launching appUnable to find Election app Please verify that the package.json has a valid "main" entry 恢复 ,并删除 dist_文件夹后, 阅读全文
posted @ 2021-08-15 18:33 三瑞 阅读(262) 评论(0) 推荐(0) 编辑
摘要:connection lost:The server closed the connection 其实很简单.mysql有个机制,就是8小时无通信,myslq就会自动关闭数据; 解决方案(2选1): 或者: 1.定时去做一个查询,就是 select * from XXX; 或者: 2.修改配置文件: 阅读全文
posted @ 2021-08-11 10:44 三瑞 阅读(111) 评论(0) 推荐(0) 编辑
摘要:electron vscode 调试时始终部分 js 进不了断点 原因:就是虽关闭了调试的程序(”调用堆栈“也是关闭),但下面的终端程序是没有关闭的,所以要关闭一下重新调试就oK了 阅读全文
posted @ 2021-08-08 11:08 三瑞 阅读(325) 评论(0) 推荐(0) 编辑
摘要:electron Uncaught TypeError: Cannot read property 'dialog' of undefined const remote = window.require('electron').remote; const dialog =remote.dialog; 阅读全文
posted @ 2021-08-07 15:02 三瑞 阅读(1028) 评论(0) 推荐(0) 编辑
摘要:引用:https://www.jianshu.com/p/cc48d4520de3 使用:https://nklayman.github.io/vue-cli-plugin-electron-builder/guide/recipes.html#debugging-with-vscode 中的例子: 阅读全文
posted @ 2021-07-29 11:11 三瑞 阅读(534) 评论(0) 推荐(0) 编辑
摘要:前言 vue-devtools是一款基于chrome游览器的插件,用于调试vue应用,这可以极大地提高我们的调试效率。接下来我们就介绍一下vue-devtools的安装。 chrome商店直接安装 vue-devtools可以从chrome商店直接下载安装,非常简单,这里就不过多介绍了。不过要注意的 阅读全文
posted @ 2021-07-25 15:43 三瑞 阅读(3981) 评论(0) 推荐(0) 编辑
摘要:__dirname is a NodeJS variable, in recent electron versions, node integration is disabled by default. When opening your BrowserWindow, you should add 阅读全文
posted @ 2021-07-25 13:17 三瑞 阅读(68) 评论(0) 推荐(0) 编辑
摘要:1、使用MSsql微软官方npm包,支持不够强大 npm install mssql@3.3.0 使用3X的版本4X的升级了 下面的用不了了。 下面是一个封装,复制至:https://blog.csdn.net/gzy11/article/details/52354441 var mssql = r 阅读全文
posted @ 2021-07-02 11:32 三瑞 阅读(609) 评论(0) 推荐(0) 编辑
摘要:vue -V 如果版本叫老,可以直接卸载,再安装最新版本、卸载 npm uninstall vue-cli -g vue create electron-vue-demo Vue CLI v4.5.13 ? Please pick a preset: Default ([Vue 2] babel, 阅读全文
posted @ 2021-06-26 09:45 三瑞 阅读(144) 评论(0) 推荐(0) 编辑
摘要:引用:https://blog.csdn.net/junshangshui/article/details/84585911 1、安装 yarn npm install -g yarn yarn --version 2、添加 yarn add electron-edge 下面是安装时出错 yarn 阅读全文
posted @ 2021-06-24 11:50 三瑞 阅读(153) 评论(0) 推荐(0) 编辑
摘要:index.js /** * 使用模板创建原生应用菜单 * 1、应用菜单(窗口菜单) * Window、Linux和Mac OS X * 2、上下文菜单 * * 1、模板 * 2、代码 * electron-packager * npm install electron-packager -g * 阅读全文
posted @ 2021-06-06 10:56 三瑞 阅读(113) 评论(0) 推荐(0) 编辑
摘要:11、在窗口中嵌入其他页面(webview组件)未成功 阅读全文
posted @ 2021-06-01 15:14 三瑞 阅读(56) 评论(0) 推荐(0) 编辑
摘要:使用HTML5 API创建子窗口,控制窗口,窗口之间的交互,从子窗口返回数据,页面来源,使用eval方法向子窗口传递数据 index.js /** * 使用HTML5 API创建子窗口 * window.open方法 * window.open(url[,title][,attributes]) * 阅读全文
posted @ 2021-05-30 21:14 三瑞 阅读(426) 评论(0) 推荐(0) 编辑
摘要:index.js /** * 消息对话框:显示简单的消息对话框 * titile 和 message * showMessageBox(options) * * 设置消息对话框的图标 * icon * * 设置消息对话框类型 * 1、默认对话框:none * 2、信息对话模型:info * 3、错误 阅读全文
posted @ 2021-05-24 21:57 三瑞 阅读(222) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示