Why can’t Visual Studio find the Node.js runtime installed by the Visual Studio Installer?


EDIT

It turns out that the nodejs version installed by Visual Studio, should not be used, but that nodejs should be installed separately. It seems that enabling nodejs for visual studio, just enables the templates. You have to install nodejs yourself. The nodejs version installed by visual studio, is used internally by visual studio, and messing with it may corrupt our visual studio install.

Below follows the original question.

Here is what I did

  1. I installed Node.js with the Visual Studio Installer:

I installed Node.js with the Visual Studio Installer

  1. I closed the installer, opened Visual Studio, closed Visual Studio and rebooted the PC.

  2. I searched my Visual Studio installation to see if Visual Studio has installed the Node.js runtime:

Where Visual Studio has installed Node.js

  1. I opened Visual Studio again to create a "Blank Node.js Console Application":

Creating a Blank Node.js Console Application

  1. When I create the project, Visual Studio claims that the Node.js runtime can’t be found:

Visual Studio can't find the Node.js installation

Question

Why can’t Visual Studio find it – is it a bug? I already know how to configure Visual Studio to find it. Should I configure Visual Studio to use the Node.js runtime installed by the Visual Studio Installer?

Thoughts

  • I noticed that the Node.js runtime is not in the path when you start a Visual Studio Developer Command prompt.
  • I wonder, if I use the Node.js runtime I found above (update it, add global packages), if it will interfere with the operation of Visual Studio.

Leave a Reply

Your email address will not be published. Required fields are marked *