diff options
| author | Joe Carstairs <65492573+Sycamost@users.noreply.github.com> | 2023-08-12 15:49:03 +0100 |
|---|---|---|
| committer | Joe Carstairs <65492573+Sycamost@users.noreply.github.com> | 2023-08-12 15:49:03 +0100 |
| commit | 37020d847e66e57913d493716e98f4dcab749262 (patch) | |
| tree | a6bfa0c49bcec61ff91465f323142db43511a122 /src/i18n/translate.ts | |
| parent | 18b85566df437ac932f59e94cbec771a4a331927 (diff) | |
Applies Prettier
Diffstat (limited to 'src/i18n/translate.ts')
| -rw-r--r-- | src/i18n/translate.ts | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/i18n/translate.ts b/src/i18n/translate.ts index c0d5620..b407e3b 100644 --- a/src/i18n/translate.ts +++ b/src/i18n/translate.ts @@ -1,9 +1,9 @@ -import type Locale from "../types/Locale"; -import type { TranslationsDictionary } from "../types/TranslationsDictionary"; -import { defaultLocale } from "./locales"; +import type Locale from '../types/Locale'; +import type { TranslationsDictionary } from '../types/TranslationsDictionary'; +import { defaultLocale } from './locales'; -export default function(locale: Locale) { - return function<T extends string>(dict: TranslationsDictionary<T>, key: T) { +export default function (locale: Locale) { + return function <T extends string>(dict: TranslationsDictionary<T>, key: T) { return dict[key][locale] ?? dict[key][defaultLocale]; - } -}
\ No newline at end of file + }; +} |
