App using OS theme

I created a new ionic vue project using ionic start, created a list, then did a web deploy. On the browser, the app has a black background but when I check the test link on my phone the app has a white background. It turns out the app somehow inherits the OS theme I am using a dark theme on my machine theme. I didnt touch the CSS.

Is this intentional? If so, where is this set in the code?


Ionic starter apps ship with a built in dark mode theme in src/theme/variables.css. We also set the color-scheme meta tag in public/index.html to ensure that system components such as the scrollbar inherit the OS dark mode theme.

1 Like