Table of Contents

Method Navigate

Namespace
Velvet
Assembly
Velvet.Docs.dll

Navigate(string, bool, string?, object?, RelativeRoutingType)

No element participates in layout while the Router the nearest RouterProvider(Router, string?) publishes handles the target.

public static ComponentNode Navigate(string to, bool replace = false, string? key = null, object? state = null, RelativeRoutingType relative = RelativeRoutingType.Route)

Parameters

to string

Absolute and route-relative targets follow UseNavigate().

replace bool

When true, replaces the current history entry instead of pushing.

key string
state object

Stored on the new history entry, as State.

relative RelativeRoutingType

How a relative to resolves, as Relative.

Returns

ComponentNode

Remarks

Redirects on mount and again when to, replace, state or relative changes.