22 lines
542 B
TypeScript
22 lines
542 B
TypeScript
|
import { NgModule, Optional, SkipSelf } from '@angular/core';
|
||
|
import { CommonModule } from '@angular/common';
|
||
|
import { HttpModule } from '@angular/http';
|
||
|
|
||
|
import { AuthService } from './auth';
|
||
|
import { throwIfAlreadyLoaded } from './module-import-guard';
|
||
|
|
||
|
@NgModule({
|
||
|
imports: [
|
||
|
CommonModule,
|
||
|
HttpModule
|
||
|
],
|
||
|
declarations: [ ],
|
||
|
exports: [ ],
|
||
|
providers: [ AuthService ]
|
||
|
})
|
||
|
export class CoreModule {
|
||
|
constructor( @Optional() @SkipSelf() parentModule: CoreModule) {
|
||
|
throwIfAlreadyLoaded(parentModule, 'CoreModule');
|
||
|
}
|
||
|
}
|