UNPKG

@httpx/assert

Version:
15 lines (11 loc) 739 B
import { S as Simplify } from './internal.types-D5VRBw-5.cjs'; type PlainObjectKey = string | number | symbol; type BasePlainObject = Record<PlainObjectKey, unknown>; interface DefaultBasePlainObject extends BasePlainObject { readonly __tag: 'default-plain-object'; } type PlainObjectDeepPartialUnknown<T> = { [P in keyof T]?: NonNullable<T[P]> extends BasePlainObject ? Simplify<PlainObjectDeepPartialUnknown<NonNullable<T[P]>>> : unknown; }; type PlainObject<TValue extends BasePlainObject = DefaultBasePlainObject> = TValue extends DefaultBasePlainObject ? Record<PlainObjectKey, unknown> : Simplify<PlainObjectDeepPartialUnknown<TValue>>; export type { BasePlainObject as B, DefaultBasePlainObject as D, PlainObject as P };