but I found this in serialport’s installation guide (https://serialport.io/docs/guide-installation):
Electron Electron is a framework for creating cross-platform desktop applications. It comes with its own version of the Node.js runtime. If you require serialport as a dependency for an Electron project, you must compile it for the version of Electron your project's using. 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; more info at Electron's README. npm install --save-dev electron-rebuild Add electron-rebuild to your project's package.json's install hook Run npm install For an example project, check out electron-serialport.
but that didn’t help either… How can I check which version of Node is electron using?