react-native-picker / picker

Picker is a cross-platform UI component for selecting an item from a list of options.
MIT License
1.5k stars 279 forks source link

Picker freezes web app when selecting NEW item #521

Open asawyers opened 1 year ago

asawyers commented 1 year ago

Hey guys, ran into an interesting bug with the Picker. Pretty normal use that works exactly as expected on iOS/Android. But for some reason on web, it freezes and crashes the entire application when selecting a NEW value (does not crash when you select the current value), with no error messages shown. Any ideas why this is happening?

Versions: "@react-native-picker/picker": "2.4.10", "react-native": "0.72.4",

<Picker
              selectedValue={selectedLocation}
              onValueChange={(itemValue, itemIndex) =>
                setSelectedLocation(itemValue)
              }
              style={styles.picker}>
              {locations.map(location => (
                <Picker.Item label={location.name} value={location.id} key={location.id} />
              ))}
            </Picker>