What's the cleanest way to remove all extras that normally come with Visual Studio API Template, things like Views and other stuff that are not needed if you just want to have a WebAPI service??
I'm assuming that the folder VIEWS is for MVC Views ...maybe I'm wrong and it's all needed to have a running APIs.
Views are optional in an MVC project. They are only used for projects where there are HTML pages involved. You can use MVC to build web services and they don't require Views.
For this, open Visual Studio and click on File menu and click on New Project. This will open New Project popup as below. In the New Project popup, expand Visual C# and select Web node in the left pane. Select ASP.NET Web Application template in the middle pane and enter the name of a project and click OK.
Select the Visual C# | Web project type from the project type tree view, then select the ASP.NET MVC 4 Web Application project type. Set the project's Name to ContactManager and the Solution name to Begin, then click OK. In the ASP.NET MVC 4 project type dialog, select the Web API project type. Click OK.
File
-> New Project
-> ASP.NET MVC 4 Web Application
. That will not have any extras such as Views.
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