OS
Learn about the OS module in Node.js.
We'll cover the following...
All the information
The os
module is a very nifty little module that allows us to get information about the OS. While it has a lot of operating system-related utility methods and properties, we will just look at a few common ones. Run the code below and see if you understand what each output means.
Press + to interact
const os = require('os');console.log("Architecture:", os.arch(), "\n")console.log("CPUs:", os.cpus(), "\n")console.log("Network interfaces:", os.networkInterfaces(), "\n")console.log("Platform:", os.platform(), "\n")console.log("Release number:", os.release(), "\n")console.log("User info:", os.userInfo(), "\n")