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

TypeScript React Native property 'target' does not exist on type 'string'

$
0
0

I'm making input component in typescript for my mobile app. I'm trying to handle change of the text in text input with useState hook, so I created this:const [password, setPassword] = useState('');now I have a input component:<TextInput value={password} onChangeText={(e) => setPassword(e.target.value)} />, and I get an error which says: "property 'target' does not exist on type 'string"


Viewing all articles
Browse latest Browse all 6287

Trending Articles



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