diff options
-rw-r--r-- | README.md | 6 | ||||
-rw-r--r-- | main.js | 4 |
2 files changed, 9 insertions, 1 deletions
@@ -69,6 +69,12 @@ npm start The debugger tools are available when running in dev mode and can be activated with keyboard shortcuts as defined here https://github.com/sindresorhus/electron-debug#features. +It can also be displayed automatically from the `SHOW_DEV_TOOLS` environment variable such as: + +```bash +SHOW_DEV_TOOLS=true npm start +``` + #### Building the production distribution ```bash @@ -22,6 +22,8 @@ const path = require('path'); const URL = require('url'); const config = require('./app/features/config'); +const showDevTools = Boolean(process.env.SHOW_DEV_TOOLS); + // We need this because of https://github.com/electron/electron/issues/18214 app.commandLine.appendSwitch('disable-site-isolation-trials'); @@ -51,7 +53,7 @@ contextMenu({ // show them automatically though. debug({ isEnabled: true, - showDevTools: false + showDevTools }); /** |