UNPKG
electron-background
Version:
latest (1.0.0)
1.0.0
launch a detached electron app
github.com/catdad/electron-background
catdad/electron-background
electron-background
/
index.js
13 lines
(10 loc)
•
287 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
13
/* jshint node: true, esnext: true */
const
{ spawn } =
require
(
'child_process'
);
const
importFrom =
require
(
'import-from'
);
const
electron =
importFrom
(process.
cwd
(),
'electron'
);
module
.
exports
=
(
args
) =>
{
spawn
(electron, args, {
detached
:
true
,
stdio
:
'ignore'
}); };