In Ionic 1 we could simply make visited links(within our own app and not external links) to be displayed in different color than the normal(not visited) links. I want to achieve the same in Ionic 2. But we’re not using href for navigation, so am not finding way to achieve this
I see. Well the easiest way would be to create your own function and apply a class when that function is called. Ionic 2 have a class built in: .activated. You can apply this class to your CSS rules to mimic the :active pseudo-class but again this wouldn’t achieve what you require.
I guess you should try creating your own function using openPage and then using an if statement to check if openPage has been called. That way you could apply a style if an element is selected without it disappearing when the resulting page is closed from the stack.
If I have time I’ll try to mock up an example for you.
I tried many things, but not yet able to figure out the solution for this
I think this is something Ionic Team should think about - as its something very important for most of the apps.
Kindly let me know once you come up with a mock up of the code …meanwhile I’ll keep trying whatever I can. Thank you