screen-management
v0.0.4
Published
A node module to turn the system's display on and off.
Downloads
7
Maintainers
Readme
screen-management
An npm module to turn the computer screen off and on again.
It works on the following platforms:
- Windows (tested on Windows 10)
- Linux (tested on Ubuntu and Raspbian)
Install the module
Import it into your project with the following command:
npm install screen-management
Or if you prefer yarn to npm install:
yarn add screen-management
How to use it
You can use this module within your code like this.
const screen = require('screen-management');
// Call this function to turn the computer screen to sleep
screen.turnOff();
// Call this function to turn on the screen (in case it was in sleep mode)
screen.turnOn();
Dependencies
No dependencies are required. The module runs native windows executables compiled using the following C# projects:
- https://github.com/fjrd84/windows-sleep-screen
- https://github.com/fjrd84/windows-wake-up-screen
Credits
Developed by F. Javier R. Donado for netvico GmbH