import { Component } from '@angular/core' ; import { TranslateService } from '@ngx-translate/core' ; import { MenuItem } from './menu/menu.common' ; declare const require ; @ Component ( { moduleId : module . id , selector : 'maestro-app' , templateUrl : './app.component.html' , } ) export class AppComponent { menuItems : MenuItem [ ] = [ { title : 'menu.home' , link : [ '/home' ] } , { title : 'menu.about' , link : [ '/about' ] } ] ; constructor ( translate ) { translate . setTranslation ( 'en' , require ( '../assets/i18n/en.json' ) ) ; translate . setDefaultLang ( 'en' ) ; translate . use ( 'en' ) ; } }