Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

React Native - IntelliSense suggesting react-native/types instead of react-native

I want to import <View from react-native but instead, what I got is react-native/types

enter image description here

How can I fix this? This is a new project start from scratch and I added TypeScript like the doc guide:

yarn add --dev @tsconfig/react-native @types/jest @types/react @types/react-test-renderer typescript

like image 884
Huan Huynh Avatar asked Aug 15 '26 22:08

Huan Huynh


1 Answers

So, for me, I had to install npm i -D @types/react-native into my project

Pretty dumb, but it worked.

like image 72
Daltron Avatar answered Aug 18 '26 16:08

Daltron



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!