I have an interface that looks like this
export interface IAppSection {
key: string;
order: number;
header: string;
content: string;
modifiedAt: string;
modifiedByEmployeeId: number;
change: 'added' | 'removed' | 'updated' | 'none';
}
What I'd like to do is have change default as none when the object this interface relates to is stored.
I have tried change: 'added' | 'removed' | 'updated' | 'none' = 'none' but this does not work.
I am sure I am doing something wrong here and would really appreciate some feedback on how I can achieve this.
interface. Though you can initialise default value from the implemented class in itsconstructor.