Skip to content

Commit

Permalink
test: add egde-case
Browse files Browse the repository at this point in the history
  • Loading branch information
mesqueeb committed Nov 14, 2022
1 parent a91e9c2 commit 8cf33a7
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/typeUtils/MergeDeep.ts
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ export type MergeDeep<
O1 extends Record<string | number | symbol, unknown>
> = O extends unknown ? (O1 extends unknown ? MergeObjectDeeply<O, O1> : never) : never

// import { PrettyPrint } from './PrettyPrint'
import { PrettyPrint } from './PrettyPrint'
// type A1 = { arr: string[]; barr?: { b: number } }
// type A2 = { arr?: number[]; barr?: { b: number } }
// type TestA = PrettyPrint<MergeDeep<A1, A2>>
Expand All @@ -109,6 +109,10 @@ export type MergeDeep<
// type C2 = { info: { date: string; very: { deep: { prop: boolean } } } }
// type TestC = PrettyPrint<MergeDeep<C1, C2>>

// type D1 = { [key in string]?: { cool: boolean } | null }
// type D2 = { [key in string]?: { notCool: boolean } | null }
// type TestD = PrettyPrint<MergeDeep<D1, D2>>

// import { Timestamp } from 'firebase/firestore'
// type T1 = { date: Timestamp }
// type T2 = { date: Timestamp }
Expand Down

0 comments on commit 8cf33a7

Please sign in to comment.