What are View Components

View components are similar to partial views, but they are much more powerful. View components don’t use model binding, and only depend on the data you provide when calling into it. A view component:

  • Renders a chunk rather than a whole response
  • Includes the same separation-of-concerns and testability benefits found between a controller and view
  • Can have parameters and business logic
  • Is typically invoked from a layout page

Source: asp.net

Leave a Reply

Your email address will not be published. Required fields are marked *