router / Class

RouteDataToken

Generic types:T

Token that declares a type of route data.

Notes

The generic type parameter is the key to guaranteed type-safety, and should always be defined.

See Also

Constructor

No documentation has been provided.

Presentation
constructor(
	private description: string
): RouteDataToken<T>;
Parameters
NameTypeDescription
description
string

Descriptive text for debugging purposes.

Properties

NameTypeDescription
[TYPE]
T | undefined
key
r
symbol

Property key that can be used to store and access the corresponding value of this token from an route's data object.

Example usage

export const NAV_STATUS = new RouteDataToken<NavStatus>("NAV_STATUS");