TL; DR
If you DO NOT want to want node-gyp depend on the installed version of Visual Studio (or do not install VS), install windows-build-tools (see below). This will fix the error and avoid future problems when updating the installed version of Visual Studio.
If you DO want node-gyp depend on the version of Visual Studio you have installed, then npm config set msvs_version 2015 instead of the 2015 tag, replace your version tag. Valid version tags: 2015 , 2014 , 2013 , 110 , 100
Commit using windows-build-tools
In node-gyp instructions you can also do
npm install --global --production windows-build-tools from the ELEVATED command line
This will install strictly the Microsoft Visual C ++ Build Tools (this will be used instead of Visual Studio for compilation) required by node-gyp , and set msvs_version only for the version installed.
After installation, you should verify that the msvs_version parameter set by windows-build-tools not been overridden. When running npm config list , msvs_version should appear under ; globalconfig C:\Users\Username\AppData\Roaming\npm\etc\npmrc ; globalconfig C:\Users\Username\AppData\Roaming\npm\etc\npmrc ; if it is not, the value set by windows-build-tools been overridden, and the overridden value should be removed. npm config delete msvs_version should delete the overridden value, and the value set by the build tools should appear in the global configuration section.
Code Bling Oct 29 '16 at 18:02 2016-10-29 18:02
source share