Open PiNengShaoNian opened 4 years ago
复现代码
function App() { const [value, setValue] = useState([]); const onChange = value => { console.log(value); setValue(value); }; return ( <div className="App"> <MultiPicker selectedValue={value} onValueChange={onChange}> <Picker indicatorClassName="my-picker-indicator"> <Picker.Item className="my-picker-view-item" value="1"> one </Picker.Item> </Picker> </MultiPicker> </div> ); }
期待效果 初始化时触发onValueChange事件
复现代码
期待效果 初始化时触发onValueChange事件