Quantcast
Channel: Active questions tagged react-native+typescript - Stack Overflow
Viewing all articles
Browse latest Browse all 6208

Typescript error trying to convert react-native flow project to typescript

$
0
0

Relatively new with react-native...

Trying conversion of a react-native flow project to react-native typescript project. Managed to work out other compile errors, but was getting the following:

Line:

import { ____ViewStyleProp_Internal as Style } from "react-native/Libraries/StyleSheet/StyleSheetTypes";

Error:

Cannot find module 'react-native/Libraries/StyleSheet/StyleSheetTypes'.ts(2307)

It doesn't seem to be finding the Libraries folder under react-native...(?) My installation of react-native under AppData\Roaming\npm\node_modules\react-native-cli\node_modules doesn't have Libraries folder... where is Libraries folder located?

Current package.json:

{
  "main": "node_modules/expo/AppEntry.js",
  "scripts": {
    "start": "expo start",
    "android": "expo start --android",
    "ios": "expo start --ios",
    "web": "expo start --web",
    "eject": "expo eject"
  },
  "dependencies": {
    "autobind-decorator": "^2.4.0",
    "expo": "^35.0.0",
    "native-base": "^2.13.8",
    "react": "16.8.3",
    "react-dom": "16.8.3",
    "react-native": "https://github.com/expo/react-native/archive/sdk-35.0.0.tar.gz",
    "react-native-web": "^0.11.7",
    "react-navigation": "^4.0.10"
  },
  "devDependencies": {
    "@types/react": "^16.8.23",
    "@types/react-native": "^0.57.65",
    "babel-preset-expo": "^7.1.0",
    "typescript": "^3.6.3"
  },
  "private": true
}

Thnks.


Viewing all articles
Browse latest Browse all 6208

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>