Skip to content

Instantly share code, notes, and snippets.

@shadow1349
Created October 31, 2021 16:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shadow1349/df47f70a72f32907b3786197d3d94af2 to your computer and use it in GitHub Desktop.
Save shadow1349/df47f70a72f32907b3786197d3d94af2 to your computer and use it in GitHub Desktop.
Non-lazy-loaded
import { NgModule } from '@angular/core';
import { Routes, RouterModule } from '@angular/router';
import { MainComponent } from './main/main.module';
const routes: Routes = [
{ path: '', redirectTo: '/main', pathMatch: 'full' },
{
path: 'main',
component: MainComponent
},
];
@NgModule({
imports: [RouterModule.forRoot(routes)],
exports: [RouterModule]
})
export class AppRoutingModule {}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment