Build Desktop Serial App with Electron

Download Electron

# 複製 Quick Start 儲存庫
$ git clone
# 進到儲存庫裡
$ cd electron-quick-start
# 安裝相依的套件並執行
$ npm install -g

Download Electron Live for Live testing (Optional)

$ npm install electron-reload

and choose one of the options to put in main.js

//Option A: soft reload(code is updated but the app doesn't restart)
//hard reload(code is updated and the app restarts)
require('electron-reload')(__dirname, {
  // Note that the path to electron may vary according to the main file
  electron: require(`${__dirname}/node_modules/electron`)

Test / Debugging Electron App

$ npm start

npm install more dependencies

A very stupid thing of electron

npm install --save-dev electron-rebuild

Release Electron App

It is stupid to let people download your raw code to run

Developing on Windows


npm install --global --production windows-build-tools

Integrate with React