Skip to content
This repository has been archived by the owner on Sep 13, 2020. It is now read-only.

Can't close after setState from onChange #357

Open
dzpt opened this issue Aug 1, 2018 · 1 comment
Open

Can't close after setState from onChange #357

dzpt opened this issue Aug 1, 2018 · 1 comment

Comments

@dzpt
Copy link

dzpt commented Aug 1, 2018

I don't know why, but after i put setState inside onChange callback, it couldn't close anymore.

Here is the code:

<SideMenu isOpen={this.state.peakOpened} openMenuOffset={layout.peakWidth} menu={this.state.peak} style={pstyle.peak} menuPosition='right' onChange={isOpen => this.changePeak(isOpen)} disableGestures={false}>

changePeak(isOpen) { this.setState({}) }

@dzpt dzpt changed the title Can't close after change state on onChange Can't close after setState from onChange Aug 1, 2018
@odarino
Copy link

odarino commented Aug 27, 2019

I faced the same issue, any update for this ?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants