asp.net mvc - Certain Razor views not publishing -


using vs 2017 mvc 5 razor views. when publish application, handful of specific views not copied over.

i'd discovered several se questions on same issue in 2010-2011 timeframe. @ time, issue build action in file's properties not set content due bug in rc has since been resolved. well, of mine do day content build action.

any reason why small number of views not making in publish?

as far i'm aware, there 2 things can cause happen.

  1. as in question, build action each view needs set "content"
  2. the view files need included in project file, in .csproj file there should line this:

    <content include="views\controllername\index.cshtml" /> 

Comments

Popular posts from this blog

networking - Vagrant-provisioned VirtualBox VM is not reachable from Ubuntu host -

c# - ASP.NET Core - There is already an object named 'AspNetRoles' in the database -

ruby on rails - ArgumentError: Missing host to link to! Please provide the :host parameter, set default_url_options[:host], or set :only_path to true -