Reputation: 523
The structure of my menu is as follows :
The default page is Home. And on clicking any menu even sub-menu that particular menu option should be highlighted. This I am able to achieve by
<MetisMenu
ref={(r) => { this.menu = r; }}
activeLinkFromLocation
classNameItemHasVisibleChild="open"
className="menu"
onSelected={(e) => {
{/* e.preventDefault();console.log('onSelected', e);*/}
}}
content={menu1}
/>
What I need to implement in addition is that by default Menu 1.1 and Menu 1.2 should collapse but the active link should still be based on the page's address.
Upvotes: 1
Views: 644