-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathi18next-parser.config.js
45 lines (34 loc) · 1.3 KB
/
i18next-parser.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
module.exports = {
createOldCatalogs: true,
// Save the \_old files
indentation: 2,
// Indentation of the catalog files
keepRemoved: true,
// Keep keys from the catalog that are no longer in code
// see below for more details
lexers: {
js: ["JsxLexer"], // if you're writing jsx inside .js files, change this to JsxLexer
ts: ["JsxLexer"],
jsx: ["JsxLexer"],
tsx: ["JsxLexer"],
default: ["JsxLexer"],
},
lineEnding: "auto",
// Control the line ending. See options at https://github.com/ryanve/eol
locales: ["en", "nl"],
// An array of the locales in your applications
output: "public/locales/$LOCALE/$NAMESPACE.json",
// Supports $LOCALE and $NAMESPACE injection
// Supports JSON (.json) and YAML (.yml) file formats
// Where to write the locale files relative to process.cwd()
input: ["src/**/*.{js,jsx,ts,tsx}"],
// An array of globs that describe where to look for source files
// relative to the location of the configuration file
sort: true,
// Whether or not to sort the catalog
// useKeysAsDefaultValue: false,
// Whether to use the keys as the default value; ex. "Hello": "Hello", "World": "World"
// The option `defaultValue` will not work if this is set to true
verbose: true,
// Display info about the parsing including some stats
};