Home > Enterprise >  How to divide HTML found in .cshtml files
How to divide HTML found in .cshtml files

Time:02-01

I've got an ASP.NET Core MVC Web App, and one of my Views has too much HTML, causing it to look messy and difficult to find stuff, is there a way to extract some of the HTML (for example a certain div) to a different .cshtml file that I can then include in the View?

CodePudding user response:

Here is a enter image description here

You can also use View Component,here is an official doc.

  •  Tags:  
  • Related