I would like to show/hide elements on a header when the user presses the menu but it does not work when the page is loaded.
Here is the workflow:
1- The user selects a menu item, in the workflow, I set the selected menu state to the right state and go the appropriate page.
2- When the page the new page is loaded, I was expecting an element with the some conditional to be shown as the condition is true.
When I debugged, I noticed that the condition was empty when the page loaded even though there was a condition. I was expecting the condition to be executed.
My goal was to be able to highlight the menu based on user selection. If you know a better to do this, please let me know.