]>
Commit | Line | Data |
---|---|---|
693b1aba C |
1 | import { NgModule, Optional, SkipSelf } from '@angular/core'; |
2 | import { CommonModule } from '@angular/common'; | |
3 | import { HttpModule } from '@angular/http'; | |
50b0c262 | 4 | import { RouterModule } from '@angular/router'; |
693b1aba | 5 | |
7ddd02c9 | 6 | import { SimpleNotificationsModule } from 'angular2-notifications'; |
5769e1db | 7 | import { ModalModule } from 'ng2-bootstrap/modal'; |
7ddd02c9 | 8 | |
693b1aba | 9 | import { AuthService } from './auth'; |
5769e1db | 10 | import { ConfirmComponent, ConfirmService } from './confirm'; |
b99290b1 | 11 | import { MenuComponent, MenuAdminComponent } from './menu'; |
693b1aba C |
12 | import { throwIfAlreadyLoaded } from './module-import-guard'; |
13 | ||
14 | @NgModule({ | |
15 | imports: [ | |
16 | CommonModule, | |
50b0c262 | 17 | HttpModule, |
7ddd02c9 C |
18 | RouterModule, |
19 | ||
5769e1db | 20 | ModalModule, |
7ddd02c9 | 21 | SimpleNotificationsModule |
693b1aba | 22 | ], |
5769e1db | 23 | |
b99290b1 | 24 | declarations: [ |
5769e1db | 25 | ConfirmComponent, |
b99290b1 C |
26 | MenuComponent, |
27 | MenuAdminComponent | |
28 | ], | |
5769e1db | 29 | |
b99290b1 | 30 | exports: [ |
7ddd02c9 C |
31 | SimpleNotificationsModule, |
32 | ||
5769e1db | 33 | ConfirmComponent, |
b99290b1 C |
34 | MenuComponent, |
35 | MenuAdminComponent | |
36 | ], | |
5769e1db C |
37 | |
38 | providers: [ | |
39 | AuthService, | |
40 | ConfirmService | |
41 | ] | |
693b1aba C |
42 | }) |
43 | export class CoreModule { | |
44 | constructor( @Optional() @SkipSelf() parentModule: CoreModule) { | |
45 | throwIfAlreadyLoaded(parentModule, 'CoreModule'); | |
46 | } | |
47 | } |