Add getCurrentYear method to FooterComponent
This method retrieves the current year dynamically. It can be used to ensure the footer displays up-to-date information without manual updates.
This commit is contained in:
@@ -7,5 +7,7 @@ import {Component} from '@angular/core';
|
|||||||
styleUrl: './footer.component.scss'
|
styleUrl: './footer.component.scss'
|
||||||
})
|
})
|
||||||
export class FooterComponent {
|
export class FooterComponent {
|
||||||
|
public getCurrentYear() {
|
||||||
|
return new Date().getFullYear();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user