Skip to content

Commit d64db1d

Browse files
fix(native): add children prop (#1705)
Co-authored-by: Josh <[email protected]>
1 parent 20d3e9a commit d64db1d

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

targets/native/src/animated.ts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { ForwardRefExoticComponent } from 'react'
1+
import { ForwardRefExoticComponent, ReactNode } from 'react'
22
import { ViewStyle, RecursiveArray } from 'react-native'
33
import {
44
AssignableKeys,
@@ -19,9 +19,10 @@ export type WithAnimated = {
1919
} & AnimatedPrimitives
2020

2121
/** The type of an `animated()` component */
22-
export type AnimatedComponent<
23-
T extends ElementType
24-
> = ForwardRefExoticComponent<AnimatedProps<ComponentPropsWithRef<T>>>
22+
export type AnimatedComponent<T extends ElementType> =
23+
ForwardRefExoticComponent<
24+
AnimatedProps<ComponentPropsWithRef<T>> & { children: ReactNode }
25+
>
2526

2627
/** The props of an `animated()` component */
2728
export type AnimatedProps<Props extends object> = {

0 commit comments

Comments
 (0)