Open Language Switcher
Opens the language switcher in the app.
Description
The openLanguageSwitcher() action opens the native language switcher so the user can change the app language.
Function Signature
await Superfans.actions.openLanguageSwitcher();| Parameter | Type | Required | Description |
|---|---|---|---|
| Nil | Nil | Nil | This action does not require any parameter. |
Structure of Response
| Status | Response |
|---|---|
| Success | { "status": "success", "message": "Language switcher opened successfully" } |
| Unexpected Error | { "status": "error", "errorId": 500, "errorHandle": "unknown-error", "message": "Something unexpected happened" } |
Example Usage
await Superfans.actions.openLanguageSwitcher();Best Practices
- Use this only on apps that support multiple languages.
- After a language change, re-read live SDK variables instead of caching previous locale-specific text.
Caveats
- This action opens the native language switcher; it does not change the language by itself.
- Language switching is available only when the app has multiple languages configured.
Updated about 7 hours ago
Did this page help you?