Given that i have following structure
type AB = {
A: string;
B: string;
}
but now i want to create a new type which extends keys but also overwrite the 'A' property. So final type should be
{
A: number;
B: string;
}
So I tried to assign AB type to my final type and append the 'A' property with new type
type final = AB & {A: number};
But it doesn't work :( So my question is; how to extend type to other with changed property type?