You can specify to not use any Layout with @layout ""
, e.g:
@layout ""
@model TravelScenarioResponse
@Model.Name
Otherwise if you want the same view to be used with multiple layouts and as a partial you can add an Views/Empty.cshtml that just contains:
@RenderBody()
And use that layout in any of the View/Template overrides documented in EmailContacts. E.g. you can decorate your Service or action with a [ClientCanSwapTemplates]
attribute, e.g:
[ClientCanSwapTemplates]
public class MyService : Service { ... }
And then the client can specify what view they want to render service with, so you can view a partial by specifying ?Template=Empty
on the query string, e.g: