LocationChangingContext Class

Definition

Contains context for a change to the browser's current location.

C#
public sealed class LocationChangingContext
Inheritance
LocationChangingContext

Constructors

Properties

CancellationToken

Gets a CancellationToken that can be used to determine if this navigation was canceled (for example, because the user has triggered a different navigation).

HistoryEntryState

Gets the state associated with the target history entry.

IsNavigationIntercepted

Gets whether this navigation was intercepted from a link.

TargetLocation

Gets the target location.

Methods

PreventNavigation()

Prevents this navigation from continuing.

Applies to

Product Versions
ASP.NET Core 7.0, 8.0, 9.0