import {ModuleWithProviders, NgModule} from '@angular/core';
import {CommonModule} from '@angular/common';
import {RouterModule} from '@angular/router';

import {SubscribeService} from '../../openaireLibrary/utils/subscribe/subscribe.service';
import {CommunityService} from "../../openaireLibrary/connect/community/community.service";

import {EmailService} from "../../openaireLibrary/utils/email/email.service";
import {SubscribeComponent} from './subscribe.component';
import {AlertModalModule} from '../../openaireLibrary/utils/modal/alertModal.module';

@NgModule({
  imports: [
    CommonModule, RouterModule, AlertModalModule
  ],
  declarations: [
    SubscribeComponent
  ],
  exports: [
    SubscribeComponent
  ]
})
export class SubscribeModule {
  static forRoot(): ModuleWithProviders {
    return {
      ngModule: SubscribeModule,
      providers: [
        SubscribeService, EmailService, CommunityService
      ]
    }
  }
}
