If you were to envision having three different types of objects, they might look something like this:
interface X {
testX: someType;
}
interface Y {
testY: someOtherType[];
}
interface Z {
testZ1: string;
testZ2: number;
}
Now imagine a master object that could potentially contain any combination of these three interfaces (although none are mandatory). For example, a valid object could be structured as follows:
{
master: {
testY: [{...}],
testZ1: 'example',
testZ2: 456
}
}
What would be the appropriate type or interface for this master object?