mirror of
https://github.com/reduxjs/redux-devtools.git
synced 2025-07-27 00:19:55 +03:00
forward port to spawned electron
This commit is contained in:
parent
7497595b81
commit
63e82169d8
|
@ -5,7 +5,11 @@ var spawn = require('cross-spawn');
|
|||
function open(app, options) {
|
||||
if (app === true || app === 'electron') {
|
||||
try {
|
||||
spawn.sync(require('electron'), [path.join(__dirname, '..', 'app')]);
|
||||
var port = options.port ? '--port=' + options.port : '';
|
||||
spawn.sync(require('electron'), [
|
||||
path.join(__dirname, '..', 'app'),
|
||||
port
|
||||
]);
|
||||
} catch (error) {
|
||||
/* eslint-disable no-console */
|
||||
if (error.message === "Cannot find module 'electron'") {
|
||||
|
|
Loading…
Reference in New Issue
Block a user