How to add html files in a Node.js project?

Feb 19, 2014 at 8:55 PM
Hi, friends.

I have created a Node.js project in Visual studio, and I want to add html files in my Views folder.

How can I do this?
Coordinator
Feb 19, 2014 at 10:58 PM
(using the February DevBuild at https://nodejstools.codeplex.com/releases/view/116275)

If you're looking to create new html files:

Right click on the Views folder and select Add->New Item
Select HTML File, type a name and click Add


If you want already existing html files:

You can drag & drop from windows explorer to the Views folder in solution explorer. This will make a copy of the file you are dragging/dropping.

You could also copy the file outside VS, and from solution explorer you'll see the file appear as a file that is excluded from the project. Then you can select that file, right-click and select Include in Project.

Or select Add->Existing Item from the Views folder context menu in solution explorer. This will also make a copy if the file isn't already present in the Views folder, unless you Add as Link (the Add button has a drop down that allows you to do that).