AppRoutes<E extends AppRouterState> constructor
AppRoutes<E extends AppRouterState> ({
- E? state,
- String? home,
Implementation
AppRoutes({E? state, String? home}) :
state = state ?? ((E == AppRouterState) ? (AppRouterState() as E) : throw Exception('custom state type, $E, must be passed in to AppRoutes'))
{
this._root = this;
this.state._routes = this;
if(home != null) _homePath = home;
}