NamespaceSystemLibrary.Common.Episerver.Extensions
HtmlHelperExtensions
public static class HtmlHelperExtensions
Inheritance
System.Object
HtmlHelperExtensions
Display a blue edit link down right in the current container
Name | Description |
---|---|
TModel |
Type | Name | Description |
---|---|---|
Microsoft.AspNetCore.Mvc.Rendering.IHtmlHelper<TModel> | html | |
EPiServer.Core.BlockData | blockData | Block/component you want a short cut to edit for |
Type | Description |
---|---|
Microsoft.AspNetCore.Html.IHtmlContent |
Property for ContentArea renders all of the content area items
Name | Description |
---|---|
TModel | |
TValue |
Type | Name | Description |
---|---|---|
Microsoft.AspNetCore.Mvc.Rendering.IHtmlHelper<TModel> | html | |
System.Linq.Expressions.Expression<Func<TModel, TValue>> | expression |
Type | Description |
---|---|
Microsoft.AspNetCore.Html.IHtmlContent |
Pass in the exception that occurs in rendering (in cshtml files).
- pass in either the exception, the string, or a tuple of the (Content Model, Exception)
Logs exceptions that occurs if any
If environment is not "prod/production" it will add the error to the HTML Response
Useful if you want to show errors in local, dev, QA, stage, but not in production, but still logging it
The div printed always has a class 'view-errored'Name | Description |
---|---|
TModel |
Type | Name | Description |
---|---|---|
Microsoft.AspNetCore.Mvc.Rendering.IHtmlHelper<TModel> | html | |
System.Object | model |
Type | Description |
---|---|
Microsoft.AspNetCore.Html.IHtmlContent |
}