mirror of
https://github.com/aspnet/JavaScriptServices.git
synced 2025-12-22 17:47:53 +00:00
36 lines
1.2 KiB
TypeScript
36 lines
1.2 KiB
TypeScript
import { NgModule } from '@angular/core';
|
|
import { CommonModule } from '@angular/common';
|
|
import { FormsModule } from '@angular/forms';
|
|
import { HttpModule } from '@angular/http';
|
|
import { RouterModule } from '@angular/router';
|
|
|
|
import { AppComponent } from './components/app/app.component';
|
|
import { NavMenuComponent } from './components/navmenu/navmenu.component';
|
|
import { HomeComponent } from './components/home/home.component';
|
|
import { FetchDataComponent } from './components/fetchdata/fetchdata.component';
|
|
import { CounterComponent } from './components/counter/counter.component';
|
|
|
|
@NgModule({
|
|
declarations: [
|
|
AppComponent,
|
|
NavMenuComponent,
|
|
CounterComponent,
|
|
FetchDataComponent,
|
|
HomeComponent
|
|
],
|
|
imports: [
|
|
CommonModule,
|
|
HttpModule,
|
|
FormsModule,
|
|
RouterModule.forRoot([
|
|
{ path: '', redirectTo: 'home', pathMatch: 'full' },
|
|
{ path: 'home', component: HomeComponent },
|
|
{ path: 'counter', component: CounterComponent },
|
|
{ path: 'fetch-data', component: FetchDataComponent },
|
|
{ path: '**', redirectTo: 'home' }
|
|
])
|
|
]
|
|
})
|
|
export class AppModuleShared {
|
|
}
|