wwb91 / blog

0 stars 0 forks source link

electron 相关 #2

Open wwb91 opened 3 years ago

wwb91 commented 3 years ago

mac 调试electron 安装包

  1. lldb path/to/build.app
  2. run --remote-debugging-port=8315
  3. chrome 打开http://localhost:8315/
wwb91 commented 3 years ago

windows 调试electron 安装包

  1. terminal run path/to/build.app --remote-debugging-port=8315
  2. chrome 打开 http://localhost:8315/
wwb91 commented 3 years ago

windows 安装包获取root权限

   "win": {
      "icon": "build/icons/icon.ico",
      // package.json 添加这一行
      "requestedExecutionLevel": "requireAdministrator",
      "target": [
        {
          "target": "nsis",
          "arch": [
            "x64",
            "ia32"
          ]
        }
      ]
    },