devtypes - v2.0.0
    Preparing search index...

    Type Alias MergeStrict<Left, Right>

    MergeStrict: Simplify<Left & Pick<Right, Exclude<keyof Right, keyof Left>>>

    Strict merge of two object types.

    Type Parameters

    • Left

      Base object type

    • Right

      Non-Overriding object type

    Similar to Merge but preserves properties from the left-hand type by only adding non-conflicting properties from the right-hand type.

    type A = { a: number; b: string };
    type B = { b: number; c: boolean };
    type Merged = MergeStrict< A, B >;
    // { a: number; b: string; c: boolean }