text: "use strict";
  
  const electron = require("electron");
  const app = electron.app;
  
  process.env.ELECTRON_DISABLE_SECURITY_WARNINGS = true;
  
  // prevent window being garbage collected
  let mainWindow;
  
  function onClosed() {
      // dereference the window
      // for multiple windows store them in an array
      mainWindow = null;
  }
  
  function createMainWindow() {
      const win = new electron.BrowserWindow({
          width: 1200,
          height: 800,
          autoHideMenuBar: true,
          webPreferences: {
              nodeIntegration: true
          }
      });
  
      win.webContents.openDevTools();
      win.loadURL(`file://${__dirname}/index.html`);
      win.on("closed", onClosed);
  
      return win;
  }
  
  app.on("window-all-closed", () => {
      if (process.platform !== "darwin") {
          app.quit();
      }
  });
  
  app.on("activate", () => {
      if (!mainWindow) {
          mainWindow = createMainWindow();
      }
  });
  
  app.on("ready", () => {
      mainWindow = createMainWindow();
  });
  