JedWatson / JedWatson/react-select
Async Select currently does not interact with defaultValue and defaultInputValue correctly
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 28k
- Forks
- 4.1k
- PR merge metrics
- No merged PRs in 30d
Description
This is because unlike <Creatable/> and the base <Select/> component, we do not wrap AsyncSelect in the StateManager, and in fact wrap the state managed Select in the makeAsyncSelect method.
The defaultValue and defaultInputValue props are still interacting as expected with the wrapped base select, however they are not currently interacting as expected with the wrapping async component.
See an example of this in CodeSandbox.
CC: @JedWatson @jossmac
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing how AsyncSelect is composed through makeAsyncSelect, StateManager, and the wrapped base Select; use the linked CodeSandbox to reproduce the behavior. Done means defaultValue and defaultInputValue interact with AsyncSelect as expected, consistently with Creatable and the base Select.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100