只是想分享。
我发现很难为这个包自定义默认 UI。官方文档没有那么有用。
幸运的是,我能够解决它。
查看答案
在 React Native 16 中。
获取输入值
<Input
...
onChange={event => getValue(event)}
/>
Run Code Online (Sandbox Code Playgroud)
产值
const getValue = event => {
console.log(event.nativeEvent.text);
};
Run Code Online (Sandbox Code Playgroud)