@polkadot/ui-settings
Manages app settings including endpoints, themes and prefixes
Usage Examples
User preferences are set as a settings object in the browser's local storage.
import settings from '@polkadot/ui-settings';
render () {
const WS_URL = settings.apiUrl();
const language = settings.il8nLang();
const languages = settings.availableLanguages();
const updatedSettings = {
...settings,
i18nLang: 'Arabic'
}
settings.set(updatedSettings);
so you need to manually reload the page after updating settings.
window.location.reload();
}
Used by
Apps that currently use the settings package