Yeah, I tried with ng-show/hide but Bootstrap has some display styles for navbar classes marked as !important, which prevents ng-show/hide to work correctly in this case (at least without messing around with the Bootstrap css classes).
I temporarily fixed the problem by replacing the line I mentioned with this:
var parent = $sub.dataSM('parent-a');
if (parent)
parent.removeClass('highlighted').attr('aria-expanded', 'false');
I don’t know if it’s the most elegant fix, but it gets the job done and no further errors raised after this.
My concern is if any stuff in memory would get reset the next time $.SmartMenus.Bootstrap.init()
is called… Because I wonder if there would be SmartMenus objects piling up in memory every time my users log off and log back in without reloading the app…