/**
 * @description A debug type that will provide an expanded type description when
 * reviewing complex types with a lot of inheritance and/or intersections
 * @private
 * Example:
    type A = { foo: string }

    function bar(newObject: PropertiesOf<A>) {...}

    bar({ foo: 'baz' }) // valid
    bar({ otherProp: 'stuff' }) // invalid
 */
export type Prettify<T> = {
    [K in keyof T]: T[K];
};
/**
 * @description Infers a union type from the values of an object, useful for enum-like consts
 * @private
 * Example:
    const Obj = {
      FOO: "foo",
      BAR: "bar",
      BAZ: []
    }

    export type Values = StringValueOf<typeof Obj>; // "foo" | "bar"
 */
export type StringValueOf<T> = {
    [K in keyof T]: T[K] extends string ? T[K] : never;
}[keyof T];
/**
 * @description Recursively applies Partial to a type
 * @private
 */
export type DeepPartial<Thing> = Thing extends Function ? Thing : Thing extends Array<infer InferredArrayMember> ? DeepPartialArray<InferredArrayMember> : Thing extends object ? DeepPartialObject<Thing> : Thing | undefined;
interface DeepPartialArray<Thing> extends Array<DeepPartial<Thing>> {
}
type DeepPartialObject<Thing> = {
    [Key in keyof Thing]?: DeepPartial<Thing[Key]>;
};
export {};
