#electron-runner
Simple wrapper around electron
package. Built on electron-quick-start
boilerplate, but it hides boilerplate code. It's meant to enable run JavaScript code in Electron without writing any electron specific code. You can run for example NodeJS application for purpose of debugging (using chrome dev tools, for example).
Note: this package is running code in renderer Electron process so if you need to access main process you should rather use other Electron boilerplate.
It allows you to specify simple configuration file, for example:
module.exports = {
url: 'file://' + require('path').join(__dirname, 'hello.html'),
menu: [],
openDevTools: true
};
usage:
npm install --save-dev electron-runner
node_modules/.bin/electron-runner PATH_FOR_CONFIG_FILE
generate HTML containers:
node_modules/.bin/electron-runner PATH_FOR_JAVASCRIPT_FILE
for example
1. node_modules/.bin/electron-runner index.js > index.html
2. ( edit url property in your config file to point at index.html)
3. node_modules/.bin/electron-runner YOUR_CONFIG.js