I have the following problem for which I did not find a working solution. I have an interface in my Angular Application:
export interface Person {
forename: string;
surname: string;
}
How would I have to define a function named getFullName() with following implementation:
getFullName(){
return this.forename + " " + this.surname;
}
I tried it directly in the interface with the function as key but it did not work...
getFullName(): string). For implementation, you need a class.