Class ClientResourceExtensions
Client resource rendering extensions
Inheritance
System.Object
ClientResourceExtensions
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: EPiServer.Framework.Web.Mvc.Html
Assembly: EPiServer.Framework.AspNet.dll
Version: 11.20.7Syntax
public static class ClientResourceExtensions
Methods
ClientResources(Page, String)
Renders client resources with specified name.
Declaration
public static string ClientResources(this Page page, string name)
Parameters
Type | Name | Description |
---|---|---|
System.Web.UI.Page | page | The page to hook the extension on. |
System.String | name | Only get resources with this name. |
Returns
Type | Description |
---|---|
System.String |
ClientResources(Page, String, ClientResourceType[])
Renders client resources with specified name and type.
Declaration
public static string ClientResources(this Page page, string name, ClientResourceType[] resourceTypes)
Parameters
Type | Name | Description |
---|---|---|
System.Web.UI.Page | page | The page to hook the extension on. |
System.String | name | Only get resources with this name. |
ClientResourceType[] | resourceTypes | Only get resources for these types. |
Returns
Type | Description |
---|---|
System.String |
CssLink(HtmlHelper, String)
Returns a CSS link tag.
Declaration
public static IHtmlString CssLink(this HtmlHelper html, string virtualPath)
Parameters
Type | Name | Description |
---|---|---|
System.Web.Mvc.HtmlHelper | html | The html helper to hook the helper on. |
System.String | virtualPath | The path to the css resource. |
Returns
Type | Description |
---|---|
System.Web.IHtmlString | A link html tag. |
RequiredClientResources(HtmlHelper, String)
Renders required client resources for specified area.
Declaration
public static IHtmlString RequiredClientResources(this HtmlHelper html, string renderingArea)
Parameters
Type | Name | Description |
---|---|---|
System.Web.Mvc.HtmlHelper | html | The HTML helper. |
System.String | renderingArea | The rendering area name to render required client resources for. |
Returns
Type | Description |
---|---|
System.Web.IHtmlString |
ScriptResource(HtmlHelper, String)
Returns a script tag.
Declaration
public static IHtmlString ScriptResource(this HtmlHelper html, string sourcePath)
Parameters
Type | Name | Description |
---|---|---|
System.Web.Mvc.HtmlHelper | html | The html helper to hook the helper on. |
System.String | sourcePath | The path to the script resource. |
Returns
Type | Description |
---|---|
System.Web.IHtmlString | A script html tag. |