import { AuthServiceService } from './../../shared/auth-service.service'; import { Component, OnInit } from '@angular/core'; @Component({ selector: 'app-footer', templateUrl: './footer.component.html', styleUrls: ['./footer.component.css'] }) export class FooterComponent implements OnInit { sectionLinks = []; awardsData = []; socialLinks = []; constructor(private authSer: AuthServiceService) { } ngOnInit() { this.authSer.onGetFooterData().subscribe( (responce) => { console.log(responce); this.sectionLinks = responce['footer']['links_section'];// this.awardsData = responce['footer']['awards_section'];// this.socialLinks = responce['footer']['socials_section']; console.log(this.sectionLinks); }, (error) => { console.log(error); } ) } }