main.js   A
last analyzed

Complexity

Total Complexity 3
Complexity/F 1.5

Size

Lines of Code 33
Function Count 2

Duplication

Duplicated Lines 0
Ratio 0 %

Test Coverage

Coverage 12.5%

Importance

Changes 7
Bugs 1 Features 0
Metric Value
cc 0
wmc 3
c 7
b 1
f 0
nc 1
mnd 1
bc 3
fnc 2
dl 0
loc 33
ccs 1
cts 8
cp 0.125
crap 0
rs 10
bpm 1.5
cpm 1.5
noi 0
1
"use strict";
2
3
/* eslint-disable no-unused-vars */
4
5
const {
6
    app
7
} = require('electron');
8
9
const mainWindow = require('./files/js/mainWindow');
10
11
12
// This method will be called when Electron has finished
13
// initialization and is ready to create browser windows.
14
// Some APIs can only be used after this event occurs.
15
app.on('ready', mainWindow.createWindow);
16
17
// Quit when all windows are closed.
18
app.on('window-all-closed', () => {
19
    // On OS X it is common for applications and their menu bar
20
    // to stay active until the user quits explicitly with Cmd + Q
21
    // if (process.platform !== 'darwin') {
22
    //     app.quit();
23
    // }
24
    app.quit();
25
});
26
27
app.on('activate', () => {
28
    // On OS X it's common to re-create a window in the app when the
29
    // dock icon is clicked and there are no other windows open.
30 2
    if (mainWindow === null) {
31
        mainWindow.createWindow();
32
    }
33
});
34
35
// In this file you can include the rest of your app's specific main process
36
// code. You can also put them in separate files and require them here.
37