Type alias DeepPartial<T>

DeepPartial<T>: Expand<{
    [key in keyof T]?: T[key] extends Primitive
        ? T[key]
        : DeepPartial<T[key]>
}>

Recursively change properties to optional on the returned type. Partial marks top-level type T properties optional, but does not recursively mark children of T or children of children, and so on.

Type Parameters

  • T