I am new to ionic and i have been trying to change a single page css like changing the background color to be something else. like green or so. i am aware i can change the same globally and i don't want to change the background color globally i want it to be only on this single page.
I have tried the below but it seems not working.
I have tried searching but i am not finding anything fitting my need
//page source code
<ion-content class="contents">
sample text goes here
</ion-content>
.contents{
background-color:red;
}
ion-content{
--background-color: var(--ion-color-danger, #f1453d);
}
the background should give me a red color for that page but it's not effecting the change
In ionic v6 Beta1 this worked for me: