I am using platform in a Node.js module on a Windows 10 computer.
Doing this I noticed, that platform cannot recognize the version number of my Windows installation (which is 10.0.14393). But platform knows, that it is running inside a Node.js application. In such a case it could fallback to Node's "os" module (which is available with Node v6+) to get my Windows version.
Showcase with platform:
var platform = require('platform');
console.log(platform.os.version); // null
Showcase with os (comes with Node.js):
var os = require('os');
console.log(os.release()); // "10.0.14393"
I am using
platform
in a Node.js module on a Windows 10 computer.Doing this I noticed, that
platform
cannot recognize the version number of my Windows installation (which is10.0.14393
). Butplatform
knows, that it is running inside a Node.js application. In such a case it could fallback to Node's "os" module (which is available with Node v6+) to get my Windows version.Showcase with
platform
:Showcase with
os
(comes with Node.js):