How can Visual Studio Node.js project with linked

2019-08-26 03:30发布

Using Visual Studio 2017 Community Edition.

I have created a new Node.js project, and I have linked a number of .js files from a shared javascript solution folder.

Unlike C# projects where I can select "Always Copy" for each of the files, and then add a custom target in the .csproj file to copy them before starting a debugging session, a node.js project does NOT allow me to set "Always Copy" - that option is simply not there in the linked file properties.

VS Node.js projects also does not support pre-build events, so I can't add a .bat file to run.

I also tried this solution creation a custom Target but that is not run on node.js projects it seems (I don't get an error, it just doesn't work).

How can I configure the project to copy all linked files before debugging (and in release mode obviously) for this type of project?

0条回答
登录 后发表回答