Imagine I have an interface:
interface Foo {
bar: SomeTypeA;
bitz: SomeTypeB;
}
And I want to use this interface to create another another interface that looks like this:
interface Foo2 {
bar: WrapperType<SomeTypeA>;
bitz: WrapperType<SomeTypeB>;
}
How would I do this programmatically, so that Foo2 is defined merely by referencing Foo instead of having to retype the structure as is?