GitHub:https://github.com/electron-userland/electron-forge
先安装:
npm install -g @electron-forge/cli
创建应用:
npx create-electron-app [my-new-app] # or yarn create electron-app [my-new-app]
可能会遇到卡死的情况,解决最后一步卡死问题
在C:\Users\用户 目录下
配置ELECTRON_MIRROR
解决的方法就是在~/.npmrc里做如下设置,
registry=https://registry.npm.taobao.org/ electron_mirror="https://npm.taobao.org/mirrors/electron/"
如果您使用的是yarn,请将 ~/.yarnrc里添加以下配置
# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. # yarn lockfile v1 registry=https://registry.npm.taobao.org/ lastUpdateCheck 1649150099300 ELECTRON_MIRROR "https://npm.taobao.org/mirrors/electron/"
留下您的脚步
最近评论