Created
May 31, 2018 05:31
-
-
Save rahulsahay19/56dd7e6b26b8785cfd5b1c0fa8c90a77 to your computer and use it in GitHub Desktop.
app.module.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { BrowserModule } from '@angular/platform-browser'; | |
import { NgModule } from '@angular/core'; | |
import { FormsModule } from '@angular/forms'; | |
import { HttpClientModule } from '@angular/common/http'; | |
import { RouterModule } from '@angular/router'; | |
import { AppComponent } from './app.component'; | |
import { NavMenuComponent } from './nav-menu/nav-menu.component'; | |
import { HomeComponent } from './home/home.component'; | |
import { CounterComponent } from './counter/counter.component'; | |
import { FetchDataComponent } from './fetch-data/fetch-data.component'; | |
import { SampleComponent } from './sample/sample.component'; | |
@NgModule({ | |
declarations: [ | |
AppComponent, | |
NavMenuComponent, | |
HomeComponent, | |
CounterComponent, | |
FetchDataComponent, | |
SampleComponent | |
], | |
imports: [ | |
BrowserModule.withServerTransition({ appId: 'ng-cli-universal' }), | |
HttpClientModule, | |
FormsModule, | |
RouterModule.forRoot([ | |
{ path: '', component: HomeComponent, pathMatch: 'full' }, | |
{ path: 'counter', component: CounterComponent }, | |
{ path: 'fetch-data', component: FetchDataComponent }, | |
{ path: 'sample', component: SampleComponent }, | |
]) | |
], | |
providers: [], | |
bootstrap: [AppComponent] | |
}) | |
export class AppModule { } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment