routes method

  1. @override
void routes(
  1. RouteManager r
)
override

Implementation

@override
void routes(RouteManager r) {
  r
    ..module(
      '/auth',
      module: AuthModule(),
      customTransition: defaultTransition,
      transition: TransitionType.custom,
    )
    ..child(
      '/',
      child: (_) => const SidebarScreen(),
      children: [
        ModuleRoute(
          '/dashboard/',
          module: DashboardModule(),
          transition: TransitionType.custom,
          customTransition: defaultTransition,
        ),
        ModuleRoute(
          '/calendar/',
          module: CalendarModule(),
          transition: TransitionType.custom,
          customTransition: defaultTransition,
        ),
        ModuleRoute(
          '/settings/',
          module: SettingsModule(),
          transition: TransitionType.custom,
          customTransition: defaultTransition,
        ),
      ],
      customTransition: defaultTransition,
      transition: TransitionType.custom,
      guards: [
        AuthGuard(redirectTo: '/auth/'),
      ],
    );
}