Skip to content
This repository has been archived by the owner on Oct 23, 2023. It is now read-only.

fix: remove ElementType from union in MergeWithAs #340

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/react/src/forwardRef.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ type MergeWithAs<
* overriding props but also because somehow it is needed to get the props correctly,
* Merge does clone the first object so that might have something to do with it.
*/
| Assign<DefaultProps, PermanentProps & { as?: Default | ElementType }>
| Assign<DefaultProps, PermanentProps & { as?: Default }>
| Assign<ComponentProps, PermanentProps & { as?: Component }>
: never

Expand Down