Dismiss reactstrap modal when clicking outside of it

Viewed 6781
3 Answers

Quoting what shinzou said as it happened to me as well:

If you set backdrop={true} you must also set toggle={fnToggle} otherwise it won't work.

Use backdrop={'static'} in Modal, So that we control the outside click. Modal won't close on clicking outside of Modal.

Eg: <Modal isOpen={this.props.isOpen} toggle={this.props.toggleModal} backdrop={'static'}>

Related