mirror of
https://github.com/siemens-mobile-hacks/node-serialport-bindings-cpp.git
synced 2026-11-26 02:47:17 +00:00
Added docs to .hbs
This commit is contained in:
parent
55c39a1af3
commit
19b271007c
3 changed files with 19 additions and 2 deletions
|
|
@ -54,6 +54,7 @@ For getting started with node-serialport, we recommend you begin with the follow
|
|||
* [Command Line Tools](#command-line-tools)
|
||||
* [Serial Port List](#serial-port-list)
|
||||
* [Serial Port Terminal](#serial-port-terminal)
|
||||
* [Building For Electron](#building-for-electron)
|
||||
|
||||
***
|
||||
|
||||
|
|
@ -330,3 +331,21 @@ $ serialport-term -l
|
|||
/dev/cu.Bluetooth-Incoming-Port
|
||||
/dev/cu.usbmodem1421 Arduino (www.arduino.cc)
|
||||
```
|
||||
|
||||
## Building for Electron
|
||||
|
||||
Electron is a framework for creating cross-platform desktop applications. Electron comes with it's own version of the Node.js runtime.
|
||||
|
||||
If you require `serialport` as a depednancy for an Electron project you need to compile it for the version of Electron you're using in your project.
|
||||
|
||||
When you first install `serialport` it will compile against the version of Node.js on your machine, not against the Node.js runtime bundled with Electron.
|
||||
|
||||
To recompile `serialport` (or any native Node.js module) for Electron you can use `electron-rebuild`.
|
||||
|
||||
1. `npm install --save-dev electron-rebuild`
|
||||
2. Delete existing Node.js binding `node_modules/serialport/build/Release/serialport.node`
|
||||
3. Run `electron-rebuild`
|
||||
1. For Windows `.\node_modules\.bin\electron-rebuild.cmd`
|
||||
2. For Linux and macOS `./node_modules/.bin/electron-rebuild`
|
||||
|
||||
For more information on `electron-rebuild` visit the official [README](https://github.com/electron/electron-rebuild/blob/master/README.md).
|
||||
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -8,4 +8,3 @@ gyp-mac-tool
|
|||
.node_pre_gyprc
|
||||
/.idea
|
||||
coverage
|
||||
/.vscode
|
||||
|
|
|
|||
|
|
@ -77,7 +77,6 @@ For getting started with node-serialport, we recommend you begin with the follow
|
|||
* [Serial Port Terminal](#serial-port-terminal)
|
||||
* [Building For Electron](#building-for-electron)
|
||||
|
||||
|
||||
***
|
||||
|
||||
## Platform Support
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue