Node.js module `os` examples
As there is no examples yet of what you can expect from the os module; Here's some samples directly from the command line, on a windows system:
C:\Users\Philipp>node
> var os = require('os');
undefined
> os.tmpdir()
'C:\\Users\\Philipp\\AppData\\Local\\Temp'
> os.endianness()
'LE'
> os.hostname()
'Philipp-PC'
> os.type()
'Windows_NT'
> os.platform()
'win32'
> os.arch()
'x64'
> os.release()
'6.1.7601'
> os.uptime()
1224.1885563
> os.loadavg()
[ 0, 0, 0 ]
> os.totalmem()
8544739328
> os.freemem()
6003707904Written by Philipp Gayret
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Os
Authors
Filed Under
Did you know?
JavaScript on a page runs with the privileges of that origin. One altered library, tag manager, or snippet can read inputs, change what people see, and call your APIs as the user.
Security insights from Cside
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#