FlintPageRoute<TProps extends FlintProps> class
Defines a strongly-typed page route contract shared between the server
(res.pageRoute) and the client (PageRegistry).
Constructors
-
FlintPageRoute({required String name, required TProps fromJson(Map<
String, dynamic> json), required FlintComponent builder(TProps props)}) -
Creates a strongly-typed page route definition.
const
Properties
- builder → FlintComponent Function(TProps props)
-
Builds the page component from a typed
TPropsinstance.final -
fromJson
→ TProps Function(Map<
String, dynamic> json) -
Deserializes raw JSON props into a typed
TPropsinstance.final - hashCode → int
-
The hash code for this object.
no setterinherited
- name → String
-
Registered component name used in
data-flint-page.final - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
buildFromJson(
Map< String, dynamic> rawProps) → FlintComponent -
Converts
rawPropsinto a component instance using fromJson and builder. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited