import { Component } from '@angular/core' ; import { Router } from '@angular/router' ; import { AuthService } from './services/auth.service' ; import { format } from 'date-fns' ; import { Scene } from 'three' ; @ Component ( { selector : 'app-root' , templateUrl : './app.component.html' , styleUrls : [ './app.component.scss' ] , } ) export class AppComponent { constructor ( private auth , private router ) { const scene = new Scene ( ) ; console . log ( format ( new Date ( ) , 'LLL do yyyy' ) ) ; } get isLoggedIn ( ) { return this . auth . isLoggedIn ( ) ; } logout ( ) { this . auth . logout ( ) ; this . router . navigate ( [ '/auth' ] ) ; } }