Class HtmxRuntimeTagHelper
- Namespace
- Htmx.Components.TagHelpers
- Assembly
- Htmx.Components.dll
Tag helper that includes the Htmx.Components client runtime.
[HtmlTargetElement("htmx-runtime")]
public class HtmxRuntimeTagHelper : TagHelper, ITagHelper, ITagHelperComponent
- Inheritance
-
HtmxRuntimeTagHelper
- Implements
- Inherited Members
- Extension Methods
Constructors
HtmxRuntimeTagHelper(IFileVersionProvider)
Initializes a new instance of the HtmxRuntimeTagHelper with the required dependencies.
public HtmxRuntimeTagHelper(IFileVersionProvider fileVersionProvider)
Parameters
fileVersionProviderIFileVersionProviderThe static asset file version provider.
Properties
ExcludeBehaviors
Gets or sets which runtime behaviors to exclude from the selected set. Valid values: "page-state-headers", "table-inline-editing", "blur-save-coordination", "request-lifecycle", "error-handling", "authentication-retry", "modal"
[HtmlAttributeName("exclude-behaviors")]
public string? ExcludeBehaviors { get; set; }
Property Value
IncludeBehaviors
Gets or sets which runtime behaviors to include. If null or empty, includes all behaviors. Valid values: "page-state-headers", "table-inline-editing", "blur-save-coordination", "request-lifecycle", "error-handling", "authentication-retry", "modal"
[HtmlAttributeName("include-behaviors")]
public string? IncludeBehaviors { get; set; }
Property Value
ViewContext
Gets or sets the current view context used to resolve versioned static asset URLs.
[ViewContext]
[HtmlAttributeNotBound]
public ViewContext ViewContext { get; set; }
Property Value
Methods
ProcessAsync(TagHelperContext, TagHelperOutput)
Processes the tag helper and renders the requested JavaScript behaviors.
public override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
Parameters
contextTagHelperContextoutputTagHelperOutput