openaire-library/shared/shared.module.ts

46 lines
795 B
TypeScript

import { NgModule, ModuleWithProviders } from '@angular/core';
import { CommonModule } from '@angular/common';
import { RouterModule } from '@angular/router';
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
const MODULES = [
// Do NOT include UniversalModule, HttpModule, or JsonpModule here
CommonModule,
RouterModule,
FormsModule,
ReactiveFormsModule
];
const PIPES = [
// put pipes here
];
const COMPONENTS = [
// put shared components here
];
@NgModule({
imports: [
...MODULES
],
declarations: [
...PIPES,
...COMPONENTS
],
exports: [
...MODULES,
...PIPES,
...COMPONENTS
]
})
export class SharedModule {
static forRoot(): ModuleWithProviders<SharedModule> {
return {
ngModule: SharedModule,
};
}
}