import { Component , ChangeDetectionStrategy } from '@angular/core' ; import { AuthService } from 'src/app/core/services/auth/auth.service' ; import { first } from 'rxjs/operators' ; @ Component ( { selector : 'app-iframe-logout-button' , templateUrl : './iframe-logout-button.component.html' , styleUrls : [ './iframe-logout-button.component.scss' ] , changeDetection : ChangeDetectionStrategy . OnPush } ) export class IframeLogoutButtonComponent { constructor ( private readonly authService ) { } public logout ( ) { this . authService . signOut ( ) . pipe ( first ( ) ) . subscribe ( ) ; } }