1

When do the call back functions for the respective handlers execute?

spender
  • 117,338
  • 33
  • 229
  • 351
amith murakonda
  • 278
  • 2
  • 15

1 Answers1

2

In the main process

The 'ready' event on app is fired when your app finished initializing and is ready to open a browser window. Since you can't open a window before that, you use the callback function to create your BrowserWindow. See the electron tutorial for example code.

In the renderer process

When you have your BrowserWindow, you can load your HTML in it. This is when the DOM is ready. You can't execute JavaScript that manipulates the DOM until it is ready. JQuery detects this state for you. This answer explains nicely how this works.

Rhayene
  • 805
  • 9
  • 20