Programmatically change ion-tabs background color

Hi there,

I use ion-tabs in my project, but wish to change the color of the tabs from within the program.

The tabs are currently set to tabs-assertive, and I can change the assertive class using Sass, but this changes it permanently, throughout the app.

Can someone please help?

Thanks,
John

You can simply use old school addClass removeClass functions on your desired element in this case the ion-tabs directive, give it an ID for ease of access and alter the classes the way you want.

You can use the Angular built in functions see this Link