React Native · APIs and utilities
App icon
Selectable icons and switching.
2 exports
Import
AppIcon
moduleSelectable icons and switching.
| Name | Type | Description |
|---|---|---|
isSupported | () => boolean | Does the device support changing the icon (iOS: supportsAlternateIcons). |
names | () => string[] | Names from ui.config icon.alternates; the primary icon ("default") is not included. |
get | () => Promise<string> | Name of the selected icon; "default" for the primary icon. |
set | (name: string) => Promise<void> | Changes the icon; "default" returns to the primary icon. - iOS: changes immediately; the system shows the user an info dialog. - Android: applied when the app goes to the background (changing the launcher component while open kills the app on some devices). get() returns the pending choice. |
DEFAULT_ICON
constantName of the primary icon.