mirror of
https://github.com/elyby/accounts-frontend.git
synced 2025-05-31 14:11:58 +05:30
Upgrade prettier before it will be removed forever
This commit is contained in:
@@ -3,7 +3,7 @@ import i18n from 'app/services/i18n';
|
||||
import { ThunkAction } from 'app/reducers';
|
||||
|
||||
export function setLocale(desiredLocale: string): ThunkAction<Promise<string>> {
|
||||
return async dispatch => {
|
||||
return async (dispatch) => {
|
||||
const locale = i18n.detectLanguage(desiredLocale);
|
||||
|
||||
dispatch(_setLocale(locale));
|
||||
|
||||
@@ -15,7 +15,7 @@ const SUPPORTED_LANGUAGES: string[] = Object.keys(supportedLocales);
|
||||
export default {
|
||||
getCountryList(): string[] {
|
||||
return SUPPORTED_LANGUAGES.map(
|
||||
locale => localeToCountryCode[locale] || locale,
|
||||
(locale) => localeToCountryCode[locale] || locale,
|
||||
);
|
||||
},
|
||||
|
||||
@@ -29,9 +29,9 @@ export default {
|
||||
*/
|
||||
getIconUrl(locale: string): string {
|
||||
// eslint-disable-next-line @typescript-eslint/no-var-requires
|
||||
const mod = require(`flag-icon-css/flags/4x3/${localeToCountryCode[
|
||||
locale
|
||||
] || locale}.svg`);
|
||||
const mod = require(`flag-icon-css/flags/4x3/${
|
||||
localeToCountryCode[locale] || locale
|
||||
}.svg`);
|
||||
|
||||
return mod.default || mod;
|
||||
},
|
||||
|
||||
@@ -10,7 +10,7 @@ const defaultState: State = {
|
||||
locale: i18n.detectLanguage(),
|
||||
};
|
||||
|
||||
export default function(
|
||||
export default function (
|
||||
state: State = defaultState,
|
||||
{ type, payload }: Action,
|
||||
): State {
|
||||
|
||||
Reference in New Issue
Block a user