app-routing.module.ts 1.23 KB
Newer Older
XFT's avatar
.  
XFT committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55
import { NgModule } from '@angular/core';
import { RouterModule, Routes } from '@angular/router';

const ROUTES: Routes = [
  {
    path: '',
    redirectTo: 'shift',
    pathMatch: 'full',
  },
  {
    path: 'shift',
    loadChildren: () =>
      import('./views/swap/swap.module').then((m) => m.SwapModule),
  },
  {
    path: 'transfer',
    loadChildren: () =>
      import('./views/transfer/transfer.module').then((m) => m.TransferModule),
  },
  {
    path: 'vault',
    loadChildren: () =>
      import('./views/wallet/wallet.module').then((m) => m.WalletModule),
  },
  {
    path: 'mpc',
    loadChildren: () =>
      import('./views/mpc/mpc.module').then((m) => m.MpcModule),
  },
  {
    path: 'swap',
    loadChildren: () =>
      import('./views/upgrade/upgrade.module').then((m) => m.UpgradeModule),
  },
  {
    path: 'stake',
    loadChildren: () =>
      import('./views/stake/stake.module').then((m) => m.StakeModule),
  },
  {
    path: 'error',
    loadChildren: () =>
      import('./views/error/error.module').then((m) => m.ErrorModule),
  },
  {
    path: '**',
    redirectTo: '/error',
  },
];

@NgModule({
  imports: [RouterModule.forRoot(ROUTES, {useHash: true})],
  exports: [RouterModule],
})
export class AppRoutingModule {}