Change the home screen application icon dynamically based on user subscription tier, seasonal events, or theme choices.
Change your home screen application icon dynamically based on user choices or seasonal events. Nativine embeds native iOS setAlternateIconName and Android activity-alias launcher bridges, enabling VIP icon customization and seasonal branding.
Dynamic App Icons let users personalize their home screen interface or unlock exclusive Pro icons. Nativine's Dynamic App Icons plugin registers alternate launcher icon aliases inside the native app bundle:
To change the home screen app icon programmatically in JavaScript, call nativine.dynamicIcons.setIcon():
nativine.dynamicIcons.setIcon({
iconAlias: 'icon_gold',
callback: 'onIconChanged',
onError: 'onIconChangeFailed'
});
function onIconChanged(result) {
console.log("App Icon changed to:", result.activeIcon);
}
| Parameter | Type | Description |
|---|---|---|
iconAlias | string | Required. Registered alternate icon alias ID (pass default to restore original icon). |
callback | string | Required. JS callback function called on successful icon switch. |
Yes. Apple's iOS displays an official OS alert ("You have changed the icon for [App Name]") when switching alternate icons.
Yes. All alternate icon PNG assets must be registered in the app manifest during compilation to comply with OS security rules.