init is not a namespace, it's a function that initializes a Neutralinojs application.
native API function. The
init function does the following tasks when it's called.
- Starts a WebSocket connection with the Neutralinojs server asynchronously.
- Registers auto-reload event handler if the
neu runcommand sets this flag) is provided.
NL_CVERSIONwith the client libary version in the
You can call native API calls right after the
init function call, as shown below.
Also, you can wrap immediate native calls with the
ready event callback if you like.
Neutralinojs client library typically queues and sends native API calls to the server when the WebSocket connection
is established. Therefore, you don't need to use the
ready event callback always.