@lindas/trifid-plugin-i18n 7.0.1 → 7.0.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.
Files changed (2) hide show
  1. package/README.md +35 -35
  2. package/package.json +4 -5
package/README.md CHANGED
@@ -1,35 +1,35 @@
1
- # trifid-plugin-i18n
2
-
3
- A Trifid plugin to add i18n support to Trifid.
4
-
5
- ## Usage
6
-
7
- Install this Trifid plugin using:
8
-
9
- ```sh
10
- npm install trifid-plugin-i18n
11
- ```
12
-
13
- The plugin needs to be added to the Trifid config under the `plugins` property.
14
- It should be loaded before the `locals` plugin and the template engine.
15
- In the following example order 5 is used which works for the default config where the `locals` plugin uses a higher order value.
16
- The config for the [i18n](https://www.npmjs.com/package/i18n) package can be set using the `config` property.
17
- The `directory` configuration field is required, and should point to the directory where you i18n JSON files are stored.
18
- See the [i18n list of configuration options](https://www.npmjs.com/package/i18n#list-of-all-configuration-options) for more details.
19
- Some default values are defined in the `index.js` file.
20
-
21
- Example of configuration:
22
-
23
- ```yaml
24
- plugins:
25
- # […] your other plugins
26
- i18n:
27
- module: "trifid-plugin-i18n"
28
- order: 5
29
- config:
30
- directory: file:locales
31
- locales:
32
- - en
33
- - de
34
- # …other configuration fields
35
- ```
1
+ # trifid-plugin-i18n
2
+
3
+ A Trifid plugin to add i18n support to Trifid.
4
+
5
+ ## Usage
6
+
7
+ Install this Trifid plugin using:
8
+
9
+ ```sh
10
+ npm install trifid-plugin-i18n
11
+ ```
12
+
13
+ The plugin needs to be added to the Trifid config under the `plugins` property.
14
+ It should be loaded before the `locals` plugin and the template engine.
15
+ In the following example order 5 is used which works for the default config where the `locals` plugin uses a higher order value.
16
+ The config for the [i18n](https://www.npmjs.com/package/i18n) package can be set using the `config` property.
17
+ The `directory` configuration field is required, and should point to the directory where you i18n JSON files are stored.
18
+ See the [i18n list of configuration options](https://www.npmjs.com/package/i18n#list-of-all-configuration-options) for more details.
19
+ Some default values are defined in the `index.js` file.
20
+
21
+ Example of configuration:
22
+
23
+ ```yaml
24
+ plugins:
25
+ # […] your other plugins
26
+ i18n:
27
+ module: "trifid-plugin-i18n"
28
+ order: 5
29
+ config:
30
+ directory: file:locales
31
+ locales:
32
+ - en
33
+ - de
34
+ # …other configuration fields
35
+ ```
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lindas/trifid-plugin-i18n",
3
- "version": "7.0.1",
3
+ "version": "7.0.2",
4
4
  "description": "Trifid plugin for i18n support",
5
5
  "type": "module",
6
6
  "main": "index.js",
@@ -34,12 +34,11 @@
34
34
  "test"
35
35
  ],
36
36
  "devDependencies": {
37
- "@lindas/trifid-core": "^7.0.0",
38
37
  "@types/i18n": "^0.13.12",
39
- "c8": "^10.1.3"
38
+ "c8": "^10.1.3",
39
+ "@lindas/trifid-core": "^7.0.2"
40
40
  },
41
41
  "publishConfig": {
42
- "access": "public",
43
- "provenance": false
42
+ "access": "public"
44
43
  }
45
44
  }