@nkzw/eslint-plugin-fbtee 0.2.1 → 0.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -51,7 +51,7 @@ export default {
51
51
  "scripts": {
52
52
  "fbtee:manifest": "fbtee manifest --src src",
53
53
  "fbtee:collect": "fbtee collect --manifest < .src_manifest.json > .source_strings.json",
54
- "fbtee:translate": "fbtee translate --translations translations/*.json --jenkins > src/translations.json"
54
+ "fbtee:translate": "fbtee translate --translations translations/*.json > src/translations.json"
55
55
  }
56
56
  }
57
57
  ```
@@ -60,7 +60,7 @@ Here is what each command does:
60
60
 
61
61
  - `fbtee manifest --src src` searches through files in the `src` directory and generates a manifest file (`.src_manifest.json`) that lists all the files translatable strings marked with `<fbt>`. In addition it creates `.enum_manifest.json` which lists all the files containing `<fbt:enum>` tags. Since these files are auto-generated, we recommend adding them to your `.gitignore`.
62
62
  - `fbtee collect --manifest < .src_manifest.json > .source_strings.json` reads the manifest file and extracts all the strings marked for translation into a `.source_strings.json` file. This file should be uploaded to your translation provider as the source for your translations.
63
- - `fbtee translate --translations translations/*.json --jenkins > src/translations.json` reads all the translations in the `translations/` directory and compiles them into a single `src/translations.json` file. This file is used by **fbtee** to display translated content in your app. The `--translations` parameter specifies the path to the translation files. The `--jenkins` flag is used to define the utilized [hash function](https://en.wikipedia.org/wiki/Jenkins_hash_function). You can adjust the `--translations` parameter to point to your translation directory. If your translations are within your app directory in a folder called `i18n`, for example, you'd use `--translations app/i18n/*.json`. The output is the translation file used by **fbtee**. This file is going to be referred to in your applications entry point, therefor it needs to be generated as part of the build, but should not be part of version control. This command requires the translations to be present in the `translations/` directory, created based on real translations of what was previously collected using the `collect` command.
63
+ - `fbtee translate --translations translations/*.json --jenkins > src/translations.json` reads all the translations in the `translations/` directory and compiles them into a single `src/translations.json` file. This file is used by **fbtee** to display translated content in your app. The `--translations` parameter specifies the path to the translation files. The `--jenkins` flag is used to define the utilized [hash function](https://en.wikipedia.org/wiki/Jenkins_hash_function). You can adjust the `--translations` parameter to point to your translation directory. If your translations are within your app directory in a folder called `i18n`, for example, you'd use `--translations app/i18n/*.json`. The output is the translation file used by **fbtee**. This file is going to be referred to in your applications entrypoint, therefore it needs to be generated as part of the build, but should not be part of version control. This command requires the translations to be present in the `translations/` directory, created based on real translations of what was previously collected using the `collect` command. Instead of outputting a single file, you can also specify `--output-dir` instead.
64
64
 
65
65
  Now, the first step is to run these commands to set up the initial strings for translation:
66
66
 
@@ -255,7 +255,7 @@ Since the `translations.json` is an auto-generated file part of your build proce
255
255
  You can install the optional eslint plugin to catch common mistakes and enforce best practices when using **fbtee**:
256
256
 
257
257
  ```bash
258
- npm install @nkzw/eslint-plugin-fbtee
258
+ npm install -D @nkzw/eslint-plugin-fbtee
259
259
  ```
260
260
 
261
261
  Add the following configuration to your ESLint configuration:
package/lib/index.cjs CHANGED
@@ -27,7 +27,7 @@ module.exports = __toCommonJS(index_exports);
27
27
  // package.json
28
28
  var package_default = {
29
29
  name: "@nkzw/eslint-plugin-fbtee",
30
- version: "0.2.1",
30
+ version: "0.2.2",
31
31
  description: "",
32
32
  keywords: [],
33
33
  repository: {
@@ -46,10 +46,10 @@ var package_default = {
46
46
  build: "tsup src/index.tsx -d lib --target=node22 --format=esm,cjs --clean --no-splitting --dts"
47
47
  },
48
48
  dependencies: {
49
- "@typescript-eslint/utils": "^8.19.1"
49
+ "@typescript-eslint/utils": "^8.29.0"
50
50
  },
51
51
  devDependencies: {
52
- "@typescript-eslint/rule-tester": "^8.19.1"
52
+ "@typescript-eslint/rule-tester": "^8.29.0"
53
53
  }
54
54
  };
55
55
 
package/lib/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  // package.json
2
2
  var package_default = {
3
3
  name: "@nkzw/eslint-plugin-fbtee",
4
- version: "0.2.1",
4
+ version: "0.2.2",
5
5
  description: "",
6
6
  keywords: [],
7
7
  repository: {
@@ -20,10 +20,10 @@ var package_default = {
20
20
  build: "tsup src/index.tsx -d lib --target=node22 --format=esm,cjs --clean --no-splitting --dts"
21
21
  },
22
22
  dependencies: {
23
- "@typescript-eslint/utils": "^8.19.1"
23
+ "@typescript-eslint/utils": "^8.29.0"
24
24
  },
25
25
  devDependencies: {
26
- "@typescript-eslint/rule-tester": "^8.19.1"
26
+ "@typescript-eslint/rule-tester": "^8.29.0"
27
27
  }
28
28
  };
29
29
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nkzw/eslint-plugin-fbtee",
3
- "version": "0.2.1",
3
+ "version": "0.2.2",
4
4
  "description": "",
5
5
  "keywords": [],
6
6
  "repository": {
@@ -16,10 +16,10 @@
16
16
  },
17
17
  "main": "lib/index.cjs",
18
18
  "dependencies": {
19
- "@typescript-eslint/utils": "^8.19.1"
19
+ "@typescript-eslint/utils": "^8.29.0"
20
20
  },
21
21
  "devDependencies": {
22
- "@typescript-eslint/rule-tester": "^8.19.1"
22
+ "@typescript-eslint/rule-tester": "^8.29.0"
23
23
  },
24
24
  "scripts": {
25
25
  "build": "tsup src/index.tsx -d lib --target=node22 --format=esm,cjs --clean --no-splitting --dts"