Skip to content

Commit

Permalink
fix(ExtendComponentProps): 修复 TOverride 的类型定义
Browse files Browse the repository at this point in the history
  • Loading branch information
fjc0k committed Jul 22, 2020
1 parent a37ba65 commit 3051055
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/react/ExtendComponentProps.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@ export type ExtendComponentProps<
| React.JSXElementConstructor<any>,
TExclude extends keyof React.ComponentProps<TComponent>,
TRef extends any = never,
TOverride extends Partial<React.ComponentProps<TComponent>> = never
TOverride extends Partial<
Record<keyof React.ComponentProps<TComponent>, any>
> = never
> = Merge<
Merge<
Omit<React.ComponentProps<TComponent>, TExclude>,
Expand Down

0 comments on commit 3051055

Please sign in to comment.