Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there a way to open the Console window on Node.js tools for Visual Studio?

I just downloaded the Node.js tools for Visual Studio and I can't find a way to open a Console window from inside VS.

It's useful to trigger npm commands like install, run build...

I know I could do it from the outside but I miss how easy it is in WebStorm, for instance.

like image 877
André Pena Avatar asked Mar 25 '15 21:03

André Pena


People also ask

How do I open the console in node JS?

To launch the REPL (Node shell), open command prompt (in Windows) or terminal (in Mac or UNIX/Linux) and type node as shown below. It will change the prompt to > in Windows and MAC. You can now test pretty much any Node.

How do I enable console in Visual Studio?

To open the console in Visual Studio, go to the main menu and select Tools > NuGet Package Manager > Package Manager Console command.

How do I open node JS command prompt in Visual Studio?

To open it, use any of these methods: Use the Ctrl + ` keyboard shortcut. Use the View | Toggle Integrated Terminal menu command. From the Command Palette ( Ctrl + Shift + P ), use the View:Toggle Integrated Terminal command.


1 Answers

You can run npm from the interactive node.js window using the .npm command.

Or you can right-click on the node.js project and chose "Open Command Prompt Here" to open a console window to run npm.

Or you can right click on the npm node in the project and use the gui tool for managing packages.

The NTVS team has a video where they talk about the npm support:

And there's also a page on the npm support in the NTVS documentation.

like image 75
jpw Avatar answered Sep 19 '22 12:09

jpw