Route testing
This commit is contained in:
parent
276677bed8
commit
2798af403d
|
@ -2,7 +2,7 @@ import { NgModule } from '@angular/core';
|
||||||
import { Routes, RouterModule } from '@angular/router';
|
import { Routes, RouterModule } from '@angular/router';
|
||||||
|
|
||||||
const routes: Routes = [
|
const routes: Routes = [
|
||||||
{ path: 'auth', loadChildren: './pages/auth/auth.module#AuthModule' },
|
{ path: 'auth', loadChildren: './pages/auth/auth.module#AuthModule' }
|
||||||
];
|
];
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
|
|
|
@ -1,3 +1 @@
|
||||||
<p>
|
<div>signin</div>
|
||||||
signin works!
|
|
||||||
</p>
|
|
|
@ -1,4 +1 @@
|
||||||
<p>
|
|
||||||
auth works!
|
|
||||||
</p>
|
|
||||||
<router-outlet></router-outlet>
|
<router-outlet></router-outlet>
|
|
@ -5,7 +5,7 @@ import { AuthComponent } from 'app/pages/auth/auth.component';
|
||||||
|
|
||||||
export const appRoutes: Routes = [{
|
export const appRoutes: Routes = [{
|
||||||
path: '', component: AuthComponent, children: [
|
path: '', component: AuthComponent, children: [
|
||||||
{ path: 'signin', loadChildren: './signin/signin.module#SigninModule' },
|
{ path: 'signin', loadChildren: './signin/signin.module#SigninModule' }
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
<p>
|
<p>
|
||||||
signin works!
|
signin works!
|
||||||
</p>
|
</p>
|
|
@ -9,10 +9,11 @@ const routes: Routes = [
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
imports: [
|
imports: [
|
||||||
CommonModule
|
CommonModule,
|
||||||
|
RouterModule.forChild(routes)
|
||||||
],
|
],
|
||||||
declarations: [
|
declarations: [
|
||||||
SigninComponent
|
SigninComponent,
|
||||||
],
|
],
|
||||||
exports: [
|
exports: [
|
||||||
RouterModule,
|
RouterModule,
|
||||||
|
|
Loading…
Reference in New Issue
Block a user