Skip to main content
Version: 7.3.2

Appearence

The 'Appearance' module provides information on the current device theme.

Example

import System from "@smartface/native/device/system";
import { Appearance } from "@smartface/native/application/application";

if (System.appearance == Appearance.LIGHT) {
console.log("Current theme is light");
}
if (System.appearance == Appearance.DARK) {
console.log("Current theme is dark");
}
for ios

The Smartface app enforces the light theme on iOS. To use the system theme, you must remove the UIUserInterfaceStyle key from the Info.plist file. Some components, such as ListView, may have display issues when the theme is changed, so it is important to test them thoroughly.