in html:
<ion-content class="bg-style">
in variables.scss:
.bg-style {
background-color: #f5f0eb;
}
the above codes do not work,but it can work in other tags like <a> <div>
and so on,and when I put the style file(.scss,such as test.scss) in the same path as the html file,it can work well also.I do not know if my question is clear,thank you for help.
use app.scss
file instead of variables.scss
.
app.scss
.bg-style {
background: #f5f0eb;
}
I would recommend you to override the ionic variables
$background-color: #f5f0eb !default;
$background-ios-color: #f5f0eb !default;
$background-md-color: #f5f0eb !default;
Check this url for more details - link
in the app.scss
file add a style
.fixed-content{
background-color: #f5f0eb;
}
it will apply to all pages, and you don't have to add a class to every ion-content
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With