Skip to content

Commit e790c3f

Browse files
authored
TaggedUnion: Fix incorrect usage example (#1211) (#1221)
1 parent bfcdbc4 commit e790c3f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

source/tagged-union.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Use-case: A shorter way to declare tagged unions with multiple members.
77
```
88
import type {TaggedUnion} from 'type-fest';
99
10-
type Tagged<Fields extends Record<string, unknown> = TaggedUnion<'type', Fields>
10+
type Tagged<Fields extends Record<string, Record<string, unknown>>> = TaggedUnion<'type', Fields>
1111
1212
// The TaggedUnion utility reduces the amount of boilerplate needed to create a tagged union with multiple members, making the code more concise.
1313
type EventMessage = Tagged<{

0 commit comments

Comments
 (0)