Skip to content

Commit ab3698f

Browse files
committed
Switch i18next-scanner to i18next-parser.
Signed-off-by: Anders Kaseorg <[email protected]>
1 parent 0fdeb1f commit ab3698f

File tree

5 files changed

+1363
-397
lines changed

5 files changed

+1363
-397
lines changed

i18next-parser.config.js

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
"use strict";
2+
3+
module.exports = {
4+
createOldCatalogs: false,
5+
defaultValue: (locale, namespace, key, value) =>
6+
locale === "en" ? key : value,
7+
indentation: "\t",
8+
input: ["app/**/*.ts"],
9+
keySeparator: false,
10+
lexers: {
11+
ts: [{lexer: "JavascriptLexer", functions: ["t.__"]}],
12+
},
13+
locales: ["en"],
14+
namespaceSeparator: false,
15+
output: "public/translations/$LOCALE.json",
16+
sort: (a, b) => (a < b ? -1 : a > b ? 1 : 0),
17+
};

i18next-scanner.config.js

Lines changed: 0 additions & 21 deletions
This file was deleted.

0 commit comments

Comments
 (0)