RazorComponentsRazorComponentBuilderExtensions.RegisterPersistentService<TPersistentService> Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Registers a persistent service with the specified render mode in the Razor components builder.
public static Microsoft.Extensions.DependencyInjection.IRazorComponentsBuilder RegisterPersistentService<TPersistentService>(this Microsoft.Extensions.DependencyInjection.IRazorComponentsBuilder builder, Microsoft.AspNetCore.Components.IComponentRenderMode renderMode);
static member RegisterPersistentService : Microsoft.Extensions.DependencyInjection.IRazorComponentsBuilder * Microsoft.AspNetCore.Components.IComponentRenderMode -> Microsoft.Extensions.DependencyInjection.IRazorComponentsBuilder
<Extension()>
Public Function RegisterPersistentService(Of TPersistentService) (builder As IRazorComponentsBuilder, renderMode As IComponentRenderMode) As IRazorComponentsBuilder
Type Parameters
- TPersistentService
The service to be registered for state management.
Parameters
- builder
- IRazorComponentsBuilder
- renderMode
- IComponentRenderMode
The IComponentRenderMode that determines to which render modes the state should be persisted.