Quantcast
Channel: Active questions tagged cocoapods - Stack Overflow
Viewing all articles
Browse latest Browse all 1022

Typescript error inside node_modules for React native project

$
0
0

The package.json in my project has"react-native-safe-area-context": "^4.7.1"

while the podfile.lock shows a different version.

  • react-native-safe-area-context (4.10.9):

which I believe is causing a typescript error

node_modules/react-native-safe-area-context/src/SafeAreaContext.tsx(148,27): error TS2345: Argument of type '(props: T, ref: React.Ref<unknown>) => React.JSX.Element' is not assignable to parameter of type 'ForwardRefRenderFunction<unknown, PropsWithoutRef<T>>'.  Types of parameters 'props' and 'props' are incompatible.    Type 'PropsWithoutRef<T>' is not assignable to type 'T'.'T' could be instantiated with an arbitrary type which could be unrelated to 'PropsWithoutRef<T>'.

tried deleting node_modules and then runningyarn installfollowed byrm -rf ios/pods ios/Podfileand then pod install

but nothing seems to fix the typescript.

Also trying install react-native-safe-area-view but to no success.


Viewing all articles
Browse latest Browse all 1022

Latest Images

Trending Articles



Latest Images