Share via


ViewComponentHelperExtensions.InvokeAsync Method

Definition

Overloads

InvokeAsync(IViewComponentHelper, String)

Invokes a view component with the specified name.

InvokeAsync(IViewComponentHelper, Type)

Invokes a view component of type componentType.

InvokeAsync<TComponent>(IViewComponentHelper)

Invokes a view component of type TComponent.

InvokeAsync<TComponent>(IViewComponentHelper, Object)

Invokes a view component of type TComponent.

InvokeAsync(IViewComponentHelper, String)

Source:
ViewComponentHelperExtensions.cs
Source:
ViewComponentHelperExtensions.cs
Source:
ViewComponentHelperExtensions.cs

Invokes a view component with the specified name.

public static System.Threading.Tasks.Task<Microsoft.AspNetCore.Html.IHtmlContent> InvokeAsync(this Microsoft.AspNetCore.Mvc.IViewComponentHelper helper, string name);

Parameters

name
String

The name of the view component.

Returns

A Task that on completion returns the rendered IHtmlContent.

Applies to

InvokeAsync(IViewComponentHelper, Type)

Source:
ViewComponentHelperExtensions.cs
Source:
ViewComponentHelperExtensions.cs
Source:
ViewComponentHelperExtensions.cs

Invokes a view component of type componentType.

public static System.Threading.Tasks.Task<Microsoft.AspNetCore.Html.IHtmlContent> InvokeAsync(this Microsoft.AspNetCore.Mvc.IViewComponentHelper helper, Type componentType);

Parameters

componentType
Type

The view component Type.

Returns

A Task that on completion returns the rendered IHtmlContent.

Applies to

InvokeAsync<TComponent>(IViewComponentHelper)

Source:
ViewComponentHelperExtensions.cs
Source:
ViewComponentHelperExtensions.cs
Source:
ViewComponentHelperExtensions.cs

Invokes a view component of type TComponent.

public static System.Threading.Tasks.Task<Microsoft.AspNetCore.Html.IHtmlContent> InvokeAsync<TComponent>(this Microsoft.AspNetCore.Mvc.IViewComponentHelper helper);

Type Parameters

TComponent

The Type of the view component.

Parameters

Returns

A Task that on completion returns the rendered IHtmlContent.

Applies to

InvokeAsync<TComponent>(IViewComponentHelper, Object)

Source:
ViewComponentHelperExtensions.cs
Source:
ViewComponentHelperExtensions.cs
Source:
ViewComponentHelperExtensions.cs

Invokes a view component of type TComponent.

public static System.Threading.Tasks.Task<Microsoft.AspNetCore.Html.IHtmlContent> InvokeAsync<TComponent>(this Microsoft.AspNetCore.Mvc.IViewComponentHelper helper, object arguments);
public static System.Threading.Tasks.Task<Microsoft.AspNetCore.Html.IHtmlContent> InvokeAsync<TComponent>(this Microsoft.AspNetCore.Mvc.IViewComponentHelper helper, object? arguments);

Type Parameters

TComponent

The Type of the view component.

Parameters

arguments
Object

Arguments to be passed to the invoked view component method.

Returns

A Task that on completion returns the rendered IHtmlContent.

Applies to