current version npm code example
Example 1: npm version
npm install -g npm@latest
Example 2: npm get version
npm view <package> version
Example 3: npm latest version windows
npm-windows-upgrade --npm-path "C:\nodejs"
npm install -g npm@latest
npm view <package> version
npm-windows-upgrade --npm-path "C:\nodejs"