electron相关

Posted by DYD on August 4, 2021

安装

如果你没有vue-cli的话需要全局安装

cnpm install -g vue-cli

然后使用vue-cli来安装electron-vue的模板

vue init simulatedgreg/electron-vue my-project

安装依赖

cd my-project

yarn # or cnpm install

进入开发模式

yarn run dev # or cnpm run dev

electron-log本地日志使用方法

By default, it writes logs to the following locations:

on Linux: ~/.config/{app name}/logs/{process type}.log on macOS: ~/Library/Logs/{app name}/{process type}.log on Windows: %USERPROFILE%\AppData\Roaming{app name}\logs{process type}.log

mac系统是command + shift + g

路径是/Users/daiyadong/Library/Logs/xxxxxx