Given a type Thing create a type Pending<Thing> with the following behavior:
- Root-level properties of type
IDare nullable - Properites that are entities, i.e. that have top-level
IDproperty, are replaced with{ id_prop: ID; }, whereid_propis name name of the entity’sIDproperty. - Same for
Arrays of entities withIDproperties, i.e.Array<{something: ID; …}>is mapped toArray<Ref<Entity>> - Primitives are loosened to allow the original type along with
stringornull, for example for easy instantiation fromFormData