mirror of
https://github.com/LemmyNet/lemmy.git
synced 2024-09-09 16:08:49 -06:00
Adding moment translation, and to i18next.ts file.
This commit is contained in:
parent
620be4ecd8
commit
3008b45a89
@ -3,6 +3,7 @@ import * as moment from 'moment';
|
|||||||
// import 'moment/locale/de';
|
// import 'moment/locale/de';
|
||||||
import 'moment/locale/zh-cn';
|
import 'moment/locale/zh-cn';
|
||||||
import 'moment/locale/fr';
|
import 'moment/locale/fr';
|
||||||
|
import 'moment/locale/sv';
|
||||||
import { getLanguage } from '../utils';
|
import { getLanguage } from '../utils';
|
||||||
import { i18n } from '../i18next';
|
import { i18n } from '../i18next';
|
||||||
|
|
||||||
|
@ -4,14 +4,16 @@ import { en } from './translations/en';
|
|||||||
import { de } from './translations/de';
|
import { de } from './translations/de';
|
||||||
import { zh } from './translations/zh';
|
import { zh } from './translations/zh';
|
||||||
import { fr } from './translations/fr';
|
import { fr } from './translations/fr';
|
||||||
|
import { sv } from './translations/sv';
|
||||||
|
|
||||||
// https://github.com/nimbusec-oss/inferno-i18next/blob/master/tests/T.test.js#L66
|
// https://github.com/nimbusec-oss/inferno-i18next/blob/master/tests/T.test.js#L66
|
||||||
// TODO don't forget to add moment locales for new languages.
|
// TODO don't forget to add moment locales for new languages.
|
||||||
const resources = {
|
const resources = {
|
||||||
en: en,
|
en,
|
||||||
de: de,
|
de,
|
||||||
zh: zh,
|
zh,
|
||||||
fr, fr,
|
fr,
|
||||||
|
sv,
|
||||||
}
|
}
|
||||||
|
|
||||||
function format(value: any, format: any, lng: any) {
|
function format(value: any, format: any, lng: any) {
|
||||||
|
Loading…
Reference in New Issue
Block a user