import { NgModule , Optional , SkipSelf } from '@angular/core' ; import { throwIfAlreadyLoaded } from '@core/module-import-guard' ; import { I18NService } from '@core/i18n/i18n.service' ; @ NgModule ( { providers : [ I18NService ] } ) export class CoreModule { constructor ( @ Optional ( ) @ SkipSelf ( ) parentModule ) { throwIfAlreadyLoaded ( parentModule , 'CoreModule' ) ; } }