We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Property 'theme' is missing
As reported and explained here: microsoft/rnx-kit#2247 (comment)
src/App.native.tsx:196:12 - error TS2741: Property 'theme' is missing in type '{ icon: string; size: number; onPress: () => void; }' but required in type 'Pick<Props, "testID" | "disabled" | "hitSlop" | "onLayout" | "pointerEvents" | "removeClippedSubviews" | "style" | "nativeID" | "collapsable" | "needsOffscreenAlphaCompositing" | ... 72 more ... | "size">'. 196 <IconButton ~~~~~~~~~~ ../../node_modules/react-native-paper/lib/typescript/components/TouchableRipple/TouchableRipple.native.d.ts:13:5 13 theme: InternalTheme; ~~~~~ 'theme' is declared here. Found 1 error in src/App.native.tsx:196
No typescript errors
Add "moduleSuffixes": [".android", ".native", ""] to tsconfig
"moduleSuffixes": [".android", ".native", ""]
replace content of TouchableRipple.native.tsx
TouchableRipple.native.tsx
type Props = React.ComponentProps<typeof Pressable> & { ... children: React.ReactNode; style?: StyleProp<ViewStyle>; theme: InternalTheme; };
by TouchableRipple.tsx content, where theme is optional
TouchableRipple.tsx
export type Props = React.ComponentPropsWithRef<typeof Pressable> & { ... children: React.ReactNode; style?: StyleProp<ViewStyle>; theme?: ThemeProp; };
The text was updated successfully, but these errors were encountered:
TouchableRipple
Successfully merging a pull request may close this issue.
Current behaviour
As reported and explained here: microsoft/rnx-kit#2247 (comment)
Expected behaviour
No typescript errors
How to reproduce?
Add
"moduleSuffixes": [".android", ".native", ""]
to tsconfigWhat have you tried so far?
replace content of
TouchableRipple.native.tsx
by
TouchableRipple.tsx
content, where theme is optionalYour Environment
The text was updated successfully, but these errors were encountered: