Skip to content

Cannot input filter in isMulti Select #4943

Answered by Rall3n
tranhoangnhi95 asked this question in Q&A
Discussion options

You must be logged in to vote

Hello @tranhoangnhi95,

the problem that causes this issue is you are rendering two different ValueContainer components based on state. Rendering a different container leads to the focused input being unfocused due to it being a completely different input.

This can be fixed by rearranging your component to render only one ValueContainer:

return <ValueContainer>
  {hasValue & myValueChild}
  {otherChildren}
</ValueContainer>;

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
1 reply
@tranhoangnhi95
Comment options

Answer selected by tranhoangnhi95
Comment options

You must be logged in to vote
1 reply
@Rall3n
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants