React-bootstrap: Any way to close the NavDropdown when using a custom MenuItem?

Created on 11 Sep 2015  ·  3Comments  ·  Source: react-bootstrap/react-bootstrap

Hi, I'm using a custom MenuItem under NavDropdown like below. But I couldn't get it closed when clicking the CustomMenuItem with NavDropdown. Previously with DropDownButton, I can use this.refs.dropdown.setDropdownState(false). Any other work around here? Thanks.


invalid question

All 3 comments

You need to invoke the this.props.onSelect that's passed down from the Dropdown parent.

Can you elaborate how to invoke it? What's the implementation?

杨小林

在 2015年9月11日,12:11,Jimmy Jia [email protected] 写道:

You need to invoke the this.props.onSelect that's passed down from the Dropdown parent.


Reply to this email directly or view it on GitHub.

Was this page helpful?
0 / 5 - 0 ratings