Skip to content

Fixed regression inputValue reset on componentWillReceiveProps ( issue #2277 )#2299

Closed
yuri-sakharov wants to merge 3 commits intoJedWatson:masterfrom
yuri-sakharov:fix/regression-on-component-will-receive-props
Closed

Fixed regression inputValue reset on componentWillReceiveProps ( issue #2277 )#2299
yuri-sakharov wants to merge 3 commits intoJedWatson:masterfrom
yuri-sakharov:fix/regression-on-component-will-receive-props

Conversation

@yuri-sakharov
Copy link

@yuri-sakharov yuri-sakharov commented Jan 17, 2018

Hi,
Following code:
if (this.state.inputValue && this.props.value !== nextProps.value && nextProps.onSelectResetsInput) { this.setState({ inputValue: this.handleInputValueChange('') }); }
was inserted for #2155 and it provides issues like #2277. Fortunately @gwyneplaine provided better solution via ref and reset inputValue in componentWillReceiveProps is redundant.

@yuri-sakharov yuri-sakharov changed the title Fixed regression inputValue reset on componentWillReceiveProps https://github.com/JedWatson/react-select/issues/2277 Fixed regression inputValue reset on componentWillReceiveProps issue #2277 Jan 17, 2018
@yuri-sakharov yuri-sakharov changed the title Fixed regression inputValue reset on componentWillReceiveProps issue #2277 Fixed regression inputValue reset on componentWillReceiveProps ( issue #2277 ) Jan 17, 2018
@jossmac jossmac added v1 labels Jul 4, 2018
@yuri-sakharov
Copy link
Author

Irrelevant for react-select 2

@yuri-sakharov yuri-sakharov deleted the fix/regression-on-component-will-receive-props branch December 4, 2018 08:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants