-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
[core] fix(InputGroup): make async control optional #4383
Conversation
[core] fix(InputGroup): make async control optionalPreviews: documentation | landing | table |
run new test only with React 16Previews: documentation | landing | table |
enable new prop in docs examplePreviews: documentation | landing | table |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks reasonable, nothing jumps out
technically this is a break for folks that were relying on the new async behavior, but now have to add the new prop to turn it on. what do we want to do about that? |
@styu yeah it is an API break for anyone who has upgraded to the range @tgreen7 @tnrich @ejose19 heads up this API break is likely coming in the next minor release |
heads up @rynorris as well |
Fixes #4375
Checklist
Changes proposed in this pull request:
Using the suggestion from #4298 (comment), this change makes "async control" of InputGroup optional, after it was enabled across the board by default in #4266 (released in @blueprintjs/core@3.31.0).
I originally wanted to support all possible
<input>
use cases out-of-the-box by default with good UX for both synchronousvalue
updates and async ones (see #4262, #4298). This turned out to be too much of a hassle, so I am now opting to make the complex async state handling behavior opt-in using a new prop calledasyncControl
.asyncControl={true}
should be used in places where applications expect that the state update to a controlled<InputGroup>
will be asynchronous, either by explicit design in their state management logic, or through a library like redux-form. I think it makes sense to hide this complexity (and potential source of bugs) behind a flag; see the docs about this:Reviewers should focus on:
Fix the linked issue, and ensure no regression