我在反应纸上使用了TextInput。但当我跟踪他们的文件时,却显示出错误。

显示错误如下:
Type '{ label: string; value: string; onChangeText: (text: string) => void; }' is missing the following properties from type 'Pick<TextInputProps, "allowFontScaling" | "autoCapitalize" | "autoCorrect" | "autoFocus" | "blurOnSubmit" | "caretHidden" | "contextMenuHidden" | "defaultValue" | ... 116 more ... | "dense">': children, onPressIn, onPressOut, autoCompletets(2739)版本:
"react": "16.13.1",
"react-native": "0.63.3",
"react-native-config": "^1.4.1",
"react-native-fast-image": "^8.3.4",
"react-native-paper": "^4.11.2",
"react-native-vector-icons": "^9.1.0"使用的反应是本地的cli而不是expo cli。
发布于 2022-03-10 07:56:29
试试这个:
<TextInputPaper
autoComplete={false}
label="Email"
value={text}
onChangeText={(text: string) =>
setText(text)
}
/>我面临着同样的类型问题,当我添加autoComplete={false}时,它就消失了
https://stackoverflow.com/questions/71418789
复制相似问题