import { NgModule, ErrorHandler } from '@angular/core';
import { FormsModule } from '@angular/forms';
import { HttpClientModule } from '@angular/common/http';
import { BrowserModule, Title } from '@angular/platform-browser';
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
import { LocationStrategy, HashLocationStrategy } from '@angular/common';
import { AppRoutes } from './app.routes';
import 'rxjs/add/operator/toPromise';

import { PRIME_COMPONENTS } from './app.prime.components';
import {
    AppSettingsService, AuthService, BroadcastService, CacheService, CoreErrorHandlerService,
    LoggingService, NotificationService, MenuService, ReferenceValuesService, UserPreferencesService
} from '@ngscaffolding/core';

import { CUSTOM_IMPORTS } from '../../custom/custom.app';

import { APP_COMPONENTS } from './app.component.list';
import { AppComponent } from './app.component';
import { AppMenuComponent, AppSubMenu } from './app.menu.component';
import { AppTopBar } from './app.topbar.component';
import { AppFooter } from './app.footer.component';
import { InlineProfileComponent } from './app.profile.component';

// Pages
import { LandingPageComponent } from './components/landingPage/landingPage.component';

// Services

@NgModule({
    imports: [
        BrowserModule,
        FormsModule,
        AppRoutes,
        HttpClientModule,
        BrowserAnimationsModule,
        PRIME_COMPONENTS,
        CUSTOM_IMPORTS
    ],
    declarations: [
        AppComponent,
        AppMenuComponent,
        AppSubMenu,
        AppTopBar,
        AppFooter,
        InlineProfileComponent,
        LandingPageComponent,
        APP_COMPONENTS
    ],
    providers: [

        // ngScaffolding-core
        { provide: ErrorHandler, useClass: CoreErrorHandlerService },
        AppSettingsService, AuthService, BroadcastService, CacheService,
        LoggingService, NotificationService, MenuService, ReferenceValuesService, UserPreferencesService
    ],
    bootstrap: [AppComponent]
})
export class AppModule { }
        Title,
        { provide: LocationStrategy, useClass: HashLocationStrategy },