You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

index.js 688B

1234567891011121314151617181920212223
  1. //This is the way to include modules with Node.js, in this case the
  2. //Electron module.
  3. //You can learn more about importing modules by searching
  4. //information about "CommonJS" modules on the internet
  5. const { app, BrowserWindow } = require('electron')
  6. //Create our main windows, here you can set the initial size.
  7. const createWindow = () => {
  8. const win = new BrowserWindow({
  9. width: 800,
  10. height: 600,
  11. })
  12. //The HTML file that will be shown, we will create this file in the next section.
  13. win.setMenuBarVisibility(false)
  14. win.loadFile('index.html')
  15. }
  16. //This is our starting event, once "Ready", create our main window.
  17. app.whenReady().then(() => {
  18. createWindow()
  19. })