| View | Partial View |
| View contains the layout page | Partial view does not contain the layout page |
| _viewstart page is rendered before any view is rendered | Partial view does not check for a _viewstart.cshtml. We cannot place any common code for a partial view within the _viewStart.cshtml page. |
| View may have markup tags like html, body, head, title, meta etc. | The Partial view is specially designed to render within the view and as a result it does not contain any mark up. |
| Partial view is more lightweight than the view. We can also pass a regular view to the RenderPartial method. | |
| If there is no layout page specified in the view, it can be considered as a partial view. In razor, there is no distinction between views and partial views as in the ASPX view engine (aspx and ascx). | |
Jul 21, 2015
View Vs Partial View
View Vs Partial View
Labels:
JOB HUNT..!!,
MVC FAQS
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment