import { NgModule } from '@angular/core'; import { Routes, RouterModule } from '@angular/router'; import { ConstantsService } from '@app/degree-planner/services/constants.service'; const routes: Routes = [ { path: '', resolve: { constants: ConstantsService }, loadChildren: './degree-planner/degree-planner.module#DegreePlannerModule', }, ]; @NgModule({ imports: [RouterModule.forRoot(routes)], exports: [RouterModule], }) export class AppRoutingModule {}