Created
January 15, 2019 13:21
-
-
Save trinhvanhuy/d4af6ee1a1c6e044465b7440479be607 to your computer and use it in GitHub Desktop.
Spinner - App Module
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, Injector } from '@angular/core'; | |
import { OAuthModule } from 'angular-oauth2-oidc'; | |
import { HttpClientModule, HTTP_INTERCEPTORS } from '@angular/common/http'; | |
import { AppComponent } from '@containers/app/app.component'; | |
import { StoreModule } from '@ngrx/store'; | |
import { EffectsModule } from '@ngrx/effects'; | |
import { StoreDevtoolsModule } from '@ngrx/store-devtools'; | |
import { | |
StoreRouterConnectingModule, | |
RouterStateSerializer, | |
} from '@ngrx/router-store'; | |
import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; | |
import { LoaderInterceptorService } from '@services/loaderInterceptor.service'; | |
@NgModule({ | |
declarations: [ | |
AppComponent, | |
], | |
imports: [ | |
BrowserModule, | |
AppRoutingModule, | |
BrowserAnimationsModule, | |
HttpClientModule, | |
StoreModule.forRoot(reducers, { metaReducers }), | |
StoreRouterConnectingModule.forRoot({ | |
stateKey: 'router' | |
}), | |
// uncomment when using debug | |
// !environment.production | |
// ? StoreDevtoolsModule.instrument({ | |
// name: '4ss', | |
// logOnly: environment.production, | |
// maxAge: 100 | |
// }) | |
// : [], | |
EffectsModule.forRoot([]), | |
EffectsModule.forFeature([ | |
]) | |
], | |
bootstrap: [AppComponent], | |
providers: [ | |
{ | |
provide: HTTP_INTERCEPTORS, | |
useClass: LoaderInterceptorService, | |
multi: true | |
} | |
] | |
}) | |
export class AppModule {} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment