parent
6db96397ea
commit
5f072fe3ab
@ -1,46 +1,40 @@
|
||||
import {Routes} from "@angular/router";
|
||||
import {HomeComponent} from "./core/components/home/home.component";
|
||||
import {PollService} from "./core/services/poll.service";
|
||||
import {PageNotFoundComponent} from "./shared/components/page-not-found/page-not-found.component";
|
||||
import { Routes } from '@angular/router';
|
||||
import { HomeComponent } from './core/components/home/home.component';
|
||||
import { PollService } from './core/services/poll.service';
|
||||
import { PageNotFoundComponent } from './shared/components/page-not-found/page-not-found.component';
|
||||
|
||||
export const routes: Routes = [
|
||||
{path: '', component: HomeComponent},
|
||||
{ path: '', component: HomeComponent },
|
||||
{
|
||||
path: 'user',
|
||||
loadChildren: () => import('./features/user-profile/user-profile.module')
|
||||
.then((m) => m.UserProfileModule),
|
||||
loadChildren: () => import('./features/user-profile/user-profile.module').then((m) => m.UserProfileModule),
|
||||
},
|
||||
{
|
||||
path: 'administration',
|
||||
loadChildren: () =>
|
||||
import('./features/administration/administration.module')
|
||||
.then((m) => m.AdministrationModule),
|
||||
resolve: {poll: PollService},
|
||||
import('./features/administration/administration.module').then((m) => m.AdministrationModule),
|
||||
// resolve: {poll: PollService},
|
||||
},
|
||||
{
|
||||
path: 'poll/:slug/administration',
|
||||
loadChildren: () =>
|
||||
import('./features/administration/administration.module')
|
||||
.then((m) => m.AdministrationModule),
|
||||
resolve: {poll: PollService},
|
||||
import('./features/administration/administration.module').then((m) => m.AdministrationModule),
|
||||
resolve: { poll: PollService },
|
||||
},
|
||||
{
|
||||
path: 'poll/:slug/consultation',
|
||||
loadChildren: () => import('./features/consultation/consultation.module')
|
||||
.then((m) => m.ConsultationModule),
|
||||
resolve: {poll: PollService},
|
||||
loadChildren: () => import('./features/consultation/consultation.module').then((m) => m.ConsultationModule),
|
||||
resolve: { poll: PollService },
|
||||
},
|
||||
{
|
||||
path: 'poll/:slug/participation',
|
||||
loadChildren: () => import('./features/participation/participation.module')
|
||||
.then((m) => m.ParticipationModule),
|
||||
resolve: {poll: PollService},
|
||||
loadChildren: () => import('./features/participation/participation.module').then((m) => m.ParticipationModule),
|
||||
resolve: { poll: PollService },
|
||||
},
|
||||
{
|
||||
path: 'oldstuff',
|
||||
loadChildren: () => import('./features/old-stuff/old-stuff.module')
|
||||
.then((m) => m.OldStuffModule),
|
||||
loadChildren: () => import('./features/old-stuff/old-stuff.module').then((m) => m.OldStuffModule),
|
||||
},
|
||||
{path: 'page-not-found', component: PageNotFoundComponent},
|
||||
{path: '**', redirectTo: 'page-not-found', pathMatch: 'full'},
|
||||
{ path: 'page-not-found', component: PageNotFoundComponent },
|
||||
{ path: '**', redirectTo: 'page-not-found', pathMatch: 'full' },
|
||||
];
|
||||
|
Loading…
Reference in new issue