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

Error Setting up Stack with react navigation using TypeScript and expo

$
0
0

loginStack.tsxerror with code

This error is popping up when I hover over the screens argument in the createStackNavigator() declaration. This is an example of what one of these screens looks like (they're all the same):

home.tsx

import React from 'react';import { View, Text } from 'react-native';import { globalStyles } from '../styles/global';export default function Home() {    return (<View style={globalStyles.container}><Text>Home Screen</Text></View>    )}

I've run these commands to install the necessary libraries:

expo install react-native-gesture-handler react-native-reanimated react-native-screens react-native-safe-area-context @react-native-community/masked-viewnpm install @react-navigation/nativenpm install @react-navigation/stack

Viewing all articles
Browse latest Browse all 6287

Trending Articles



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