property Process.version
The process.version property contains the Node.js version string.
import { version } from 'node:process';
console.log(`Version: ${version}`);
// Version: v14.8.0
To get the version string without the prepended v, useprocess.versions.node.
Type #
string