-
Notifications
You must be signed in to change notification settings - Fork 4.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to disable option Groups to support options with property "options" #3706
Comments
Hi @ncrum, I wanted to check in and see if you ended up implementing one of your proposed solutions, thanks! |
@bladey I did not. Feel free to take it, as I'm not likely to get around to it, thanks! |
I was passing
All this while I have been doing the same to other The workaround is to omit the |
Just ran into this issue myself and ended up doing the same workaround after searching for and failing to find a prop to disable the group behavior. |
I would love to hear your work-around right now because it's preventing my project from compiling, and it still happens now. |
@octavian-ene I basically did something like this to remove the
|
Just came across this myself, it took a while to figure out it was all breaking because my own data had the key "options" in it. Would be nice if it didn't make that presumption or looked for a more unique key to exist, like |
This code assumes that if an Option has a
options
property then it MUST be a Group. In my use case, I have no need for a Group, but my option object does indeed have anoptions
property, and so the Select assumes it has option groups anyways and excludes most of my options with emptyoptions
property.It seems to me the solution probably involves one or more of the following:
Select
to allow enabling of groups, e.g.isGrouping
,isGroups
, etc. Make that part of the condition here instead.groupOptionsKey
, or a functional version, e.g.getGroupOptions
.Example (notice "Ocean" is filtered out): https://codesandbox.io/s/option-groups-bug-s3pzm
If you guys agree with the issue and any of the solutions and need someone to make a PR, I'd be happy to if it helps. Thanks.
The text was updated successfully, but these errors were encountered: