Skip to content

Conversation

@YoussefHenna
Copy link
Collaborator

  • Was producing 'invalid options' error even when valid.
    • typeof firstOption === ("string" || "number") does not seem to do what I intended, which is check if it is a string or a number
    • firstOption.value or firstOption.label could be 0 which is falsy

@YoussefHenna YoussefHenna added the legacy For a legacy branch using an older Expo version label Sep 10, 2023
@linear
Copy link

linear bot commented Sep 10, 2023

P-4051 Picker throwing error

I fixed this on draftbit but you can take a look at stagingbit app.

my options array was

[{"label" : "Male", "value": 0}, {"label" : "Female", "value": 1}]

and this was working before the last deployment. However, it throws this error even though it fulfils the requirements

image.png

@github-actions
Copy link

Published version: @draftbit/ui@47.8.1-9dc41e.2

@YoussefHenna YoussefHenna merged commit 9f81383 into 47 Sep 10, 2023
@YoussefHenna YoussefHenna deleted the youssef/p-4051-picker-throwing-error47 branch September 10, 2023 16:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

legacy For a legacy branch using an older Expo version

Development

Successfully merging this pull request may close these issues.

2 participants