Skip to content

Commit 83ab873

Browse files
committed
fix: optional types
1 parent 332547e commit 83ab873

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ export type MapperValue<RP, P> = ReactElement<any> | MapperComponent<RP, P>
4141

4242
export type Mapper<RP, P> = Record<keyof RP, MapperValue<RP, P>>
4343

44-
export function adopt<RP, P = {}>(mapper: Mapper<RP, P>): RPC<RP, P> {
44+
export function adopt<RP = any, P = {}>(mapper: Mapper<RP, P>): RPC<RP, P> {
4545
if (!values(mapper).some(isValidRenderProp)) {
4646
throw new Error(
4747
'The render props object mapper just accept valid elements as value'

0 commit comments

Comments
 (0)