Greatly reduced module imports hierarchy

- it is no longer needed manually importing numerous modules as
CoreModule re-exports them
This commit is contained in:
Denys Vuika
2016-09-23 13:58:40 +01:00
parent a92716c438
commit dd2d41db2c
15 changed files with 21 additions and 120 deletions

View File

@@ -18,11 +18,8 @@
import { NgModule, Component, OnInit } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { FormsModule } from '@angular/forms';
import { HttpModule, Http } from '@angular/http';
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
import { TranslateModule, TranslateLoader } from 'ng2-translate/ng2-translate';
import { CoreModule, AlfrescoTranslationLoader } from 'ng2-alfresco-core';
import { CoreModule } from 'ng2-alfresco-core';
import { DataTableModule } from 'ng2-alfresco-datatable';
import { DocumentListModule } from 'ng2-alfresco-documentlist';
@@ -214,16 +211,9 @@ class DocumentListDemo implements OnInit {
@NgModule({
imports: [
BrowserModule,
FormsModule,
HttpModule,
CoreModule.forRoot(),
DataTableModule,
DocumentListModule.forRoot(),
TranslateModule.forRoot({
provide: TranslateLoader,
useFactory: (http) => new AlfrescoTranslationLoader(http),
deps: [Http]
})
DocumentListModule.forRoot()
],
declarations: [ DocumentListDemo ],
bootstrap: [ DocumentListDemo ]