I'm trying to publish my ASP.NET Core 5 MVC application from Visual Studio to IIS Web Server (on VPS). But all my Areas
folders, Cshtml files, view components etc, have not been published - only the wwwroot
folder and its contents have been uploaded to the server. I saw about project.json
, but .NET 5 doesn't use it anymore.
PS: when I try publishing clicking directly from the "Area" folder selected, the files are published, but the .Cs files are published too.
How can I fix it?
On publishing to Microsoft Azure, everything goes fine. But to my VPS it is not working as I would like to.