import { NgModule } from '@angular/core' ; import { Routes , RouterModule } from '@angular/router' ; import { DashboardComponent } from '@app/main/dashboard/dashboard.component' ; const routes = [ { path : '' , children : [ { path : 'dashboard' , component : DashboardComponent , data : { permission : 'Pages.Tenant.Dashboard' } } , { path : '' , redirectTo : 'dashboard' , pathMatch : 'full' } , { path : '**' , redirectTo : 'dashboard' } ] , } , ] ; @ NgModule ( { imports : [ RouterModule . forChild ( routes ) ] , exports : [ RouterModule ] } ) export class MainRoutingModule { }