Страница 404 доработка
This commit is contained in:
Kataev Denis 2022-09-29 10:15:21 +04:00
parent a22479dffd
commit 86eaca953e
2 changed files with 7 additions and 2 deletions

View File

@ -3,6 +3,6 @@
<div class="not-found-page__container">
<h1>404</h1>
<p>Упс, что-то пошло не так!</p>
<button>Вернуться на главную</button>
<button (click)="routeHome()">Вернуться на главную</button>
</div>
</div>

View File

@ -1,4 +1,5 @@
import { Component, OnInit } from '@angular/core';
import { Router } from '@angular/router';
@Component({
selector: 'app-not-found',
@ -7,9 +8,13 @@ import { Component, OnInit } from '@angular/core';
})
export class NotFoundComponent implements OnInit {
constructor() { }
constructor(private router: Router) { }
ngOnInit(): void {
}
routeHome() {
this.router.navigate(['/']);
}
}