2019-09-18 06:02:21 +00:00
|
|
|
import { NgModule } from '@angular/core';
|
|
|
|
import { Routes, RouterModule } from '@angular/router';
|
2019-09-23 05:23:24 +00:00
|
|
|
import { AppAuthGuard } from './guards/auth.guard';
|
2019-09-18 06:02:21 +00:00
|
|
|
|
|
|
|
const routes: Routes = [
|
|
|
|
{ path: '', redirectTo: '/messenger', pathMatch: 'full' },
|
|
|
|
{
|
|
|
|
path: 'messenger',
|
2019-10-25 00:46:05 +00:00
|
|
|
loadChildren: () =>
|
|
|
|
import('./pages/messenger/messenger.page.module').then(
|
|
|
|
m => m.AppMessengerPageModule
|
|
|
|
),
|
2020-02-07 04:33:30 +00:00
|
|
|
canActivate: [AppAuthGuard]
|
2019-09-18 06:02:21 +00:00
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'account',
|
2019-10-25 00:46:05 +00:00
|
|
|
loadChildren: () =>
|
|
|
|
import('./pages/account/account.page.module').then(
|
|
|
|
m => m.AppAccountPageModule
|
2020-02-07 04:33:30 +00:00
|
|
|
)
|
2019-10-02 08:12:51 +00:00
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'template',
|
2019-10-25 00:46:05 +00:00
|
|
|
loadChildren: () =>
|
|
|
|
import('./pages/template/template.page.module').then(
|
|
|
|
m => m.AppTemplatePageModule
|
2020-02-07 04:33:30 +00:00
|
|
|
)
|
|
|
|
}
|
2019-09-18 06:02:21 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
@NgModule({
|
2020-02-11 07:35:37 +00:00
|
|
|
imports: [
|
|
|
|
RouterModule.forRoot(routes, { useHash: true, enableTracing: false })
|
|
|
|
],
|
2020-02-07 04:33:30 +00:00
|
|
|
exports: [RouterModule]
|
2019-09-18 06:02:21 +00:00
|
|
|
})
|
|
|
|
export class AppRoutingModule {}
|