TronNatthakorn / react-native-wheel-pick

Apache License 2.0
177 stars 85 forks source link

SelectedValue can only be selected up to 23 indexes #44

Open A-ANing opened 11 months ago

A-ANing commented 11 months ago
const datas= Array.from({ length: 3000 }, (_, index) => {
    var val = 1 + index
    return {
        value: val,
        label: val + "ed"
    }
});
<Picker        
     selectedValue={200}
     pickerData={datas}
     onValueChange={value => { console.log(value) }} 
 />

Actually selected 24ed

"@react-native-community/datetimepicker": "^7.4.1", "@react-native-picker/picker": "^2.4.10", "react-native": "0.72.3", "react-native-wheel-pick": "^1.2.2"

A-ANing commented 11 months ago

I used picker.setSelectedItemPosition (index, false) Solved the problem