There are two ways to turn off a computer: by graceful shutdown, or hard shutdown. Graceful shutdown means that the OS (operating system) can safely shut down its processes and close all connections, however long that takes. This helps to prevent accidental data loss or other unexpected problems if the shutdown is performed intentionally by the user.
What Does Require Do
When a module is loaded using the require() function, the module’s code is executed and the exports object of the module is returned. The require() function can be used to load local files as well as modules installed from npm.