The preceding section described using a built-in Electron API to hook into the some of the operating system components. However, what if the Electron does not provide an API to implement your requirement. You should search for a corresponding npm module in the npm registry. In this section, let's check how we can control the display properties of a machine from your Electron application. In a real-world scenario, it's very rare to have this type of requirement. However, this will give you a detailed description about dealing with machine components. The operating system itself provides a lot of utility functions that can be used to interact with crucial internal components. These utilities can be executed via a terminal or command-line prompt.
If an operating system provides a utility program and the application user have access to it, then you can easily control that utility using Node.js shell. Let's take a look at the display properties example here. The main...