Used of [routerLink]. Now is not blink
This commit is contained in:
parent
8f86c6ed53
commit
8312bfb121
|
|
@ -20,10 +20,10 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="container d-flex justify-content-between align-items-center">
|
<div class="container d-flex justify-content-between align-items-center">
|
||||||
<!-- Navbar links -->
|
<!-- Navbar links -->
|
||||||
<a class="navbar-brand" href="/about-me">{{ 'topBar.aboutMe' | translate }}</a>
|
<a class="navbar-brand" [routerLink]="'/about-me'">{{ 'topBar.aboutMe' | translate }}</a>
|
||||||
<a class="navbar-brand" href="/asset-calculator">{{ 'topBar.depreciationCalculator' | translate }}</a>
|
<a class="navbar-brand" [routerLink]="'/asset-calculator'">{{ 'topBar.depreciationCalculator' | translate }}</a>
|
||||||
<a class="navbar-brand" href="/quotes">{{ 'topBar.courses' | translate }}</a>
|
<a class="navbar-brand" [routerLink]="'/quotes'">{{ 'topBar.courses' | translate }}</a>
|
||||||
<a class="navbar-brand" href="/friendly-pages">{{ 'topBar.friendlyPages' | translate }}</a>
|
<a class="navbar-brand" [routerLink]="'/friendly-pages'">{{ 'topBar.friendlyPages' | translate }}</a>
|
||||||
</div>
|
</div>
|
||||||
</nav>
|
</nav>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,12 +1,12 @@
|
||||||
import { Component, HostListener, OnDestroy } from '@angular/core';
|
import { Component, HostListener, OnDestroy } from '@angular/core';
|
||||||
import { RouterOutlet } from '@angular/router';
|
import { RouterOutlet, RouterModule } from '@angular/router';
|
||||||
import { TranslateService, TranslateModule } from '@ngx-translate/core';
|
import { TranslateService, TranslateModule } from '@ngx-translate/core';
|
||||||
import { Subscription } from 'rxjs';
|
import { Subscription } from 'rxjs';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-root',
|
selector: 'app-root',
|
||||||
standalone: true,
|
standalone: true,
|
||||||
imports: [RouterOutlet, TranslateModule],
|
imports: [RouterOutlet, TranslateModule, RouterModule],
|
||||||
templateUrl: './app.component.html',
|
templateUrl: './app.component.html',
|
||||||
styleUrls: ['./app.component.css'], // Fixed typo
|
styleUrls: ['./app.component.css'], // Fixed typo
|
||||||
})
|
})
|
||||||
|
|
|
||||||
|
|
@ -9,9 +9,8 @@ import { FriendlyPagesComponent } from './friendly-pages/friendly-pages.componen
|
||||||
|
|
||||||
export const routes: Routes = [
|
export const routes: Routes = [
|
||||||
{
|
{
|
||||||
path: "",
|
path: '', redirectTo: 'asset-calculator', pathMatch: 'full'
|
||||||
title: "Kalkulator amortyzacyjny",
|
|
||||||
component:AssetCalculatorComponent
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: "about-me",
|
path: "about-me",
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue