I would like to do some client side-only web development using VS 2015. I don't need any server-side code, and I don't need any .net code compilation going on. However, I would like javascript intellisense, specifically in this case for angularjs (presumably using the _references.js file) and bower support.
How could I achieve this in Visual Studio 2015? I have been looking at the ASP.net 5 templates:
The closest-looking thing I can see is the 'Empty' option, which has no controllers. This also has the little 'dependencies' arrow visible in the tree, and it seems trivial to add bower.json and _references.js (which according to my limited understanding, is what gets the intellisense working properly.)
However, it also has 'Startup.cs' that sets up various services that I don't need for my use case. Removing this file 'naïvely' gives Error CS5001 Program does not contain a static 'Main' method suitable for an entry point when I build the xproj. Unlike with a .csproj, there's no ability to change the output type of the project, and in any case, I don't want to be creating a .dll. I guess the next step might be to use a custom version of Microsoft.DNX.targets, but at this point I seem to be wandering off the beaten track a bit.
So, a 'Web Site'...
...doesn't have the 'Startup.cs', but it doesn't seem to be able to do anything with bower either.
I'd be interested to know how to do this in projects/templates for earlier versions of ASP.net too, if they could offer the same capabilities.
Startup
class is useful for static file service. It what actually boots up your 'server'. ASPNET5 empty template is perfect for the job.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With