intlayer 4.1.3 → 4.1.5
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 +26 -27
- package/package.json +8 -8
package/README.md
CHANGED
|
@@ -61,7 +61,7 @@ const config: IntlayerConfig = {
|
|
|
61
61
|
export default config;
|
|
62
62
|
```
|
|
63
63
|
|
|
64
|
-
> For a complete list of available parameters, refer to the [configuration documentation](https://intlayer.org
|
|
64
|
+
> For a complete list of available parameters, refer to the [configuration documentation](https://intlayer.org/doc/concept/configuration).
|
|
65
65
|
|
|
66
66
|
## Example of usage
|
|
67
67
|
|
|
@@ -69,7 +69,7 @@ With Intlayer, you can declare your content in a structured way anywhere in your
|
|
|
69
69
|
|
|
70
70
|
By default, Intlayer scans for files with the extension `.content.{ts,tsx,js,jsx,mjs,cjs}`.
|
|
71
71
|
|
|
72
|
-
> can modify the default extension by setting the `contentDir` property in the [configuration file](https://intlayer.org
|
|
72
|
+
> can modify the default extension by setting the `contentDir` property in the [configuration file](https://intlayer.org/doc/concept/configuration).
|
|
73
73
|
|
|
74
74
|
```bash codeFormat="typescript"
|
|
75
75
|
.
|
|
@@ -134,18 +134,17 @@ A typical output might look like:
|
|
|
134
134
|
|
|
135
135
|
```bash
|
|
136
136
|
.
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
│
|
|
140
|
-
│
|
|
141
|
-
|
|
142
|
-
│
|
|
143
|
-
│
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
└──
|
|
148
|
-
└── intlayer.d.ts # Contain the auto-generated type definitions of Intlayer
|
|
137
|
+
└── .intlayer
|
|
138
|
+
├── dictionary # Contain the dictionary of your content
|
|
139
|
+
│ ├── client-component.json
|
|
140
|
+
│ └── server-component.json
|
|
141
|
+
├── main # Contain the entry point of your dictionary to be used in your application
|
|
142
|
+
│ ├── dictionary.cjs
|
|
143
|
+
│ └── dictionary.mjs
|
|
144
|
+
└── types # Contain the auto-generated type definitions of your dictionary
|
|
145
|
+
├── intlayer.d.ts # Contain the auto-generated type definitions of Intlayer
|
|
146
|
+
├── client-component.d.ts
|
|
147
|
+
└── server-component.d.ts
|
|
149
148
|
```
|
|
150
149
|
|
|
151
150
|
### Build i18next resources
|
|
@@ -167,7 +166,7 @@ const config: IntlayerConfig = {
|
|
|
167
166
|
};
|
|
168
167
|
```
|
|
169
168
|
|
|
170
|
-
> For a complete list of available parameters, refer to the [configuration documentation](https://intlayer.org
|
|
169
|
+
> For a complete list of available parameters, refer to the [configuration documentation](https://intlayer.org/doc/concept/configuration).
|
|
171
170
|
|
|
172
171
|
Output:
|
|
173
172
|
|
|
@@ -217,7 +216,7 @@ const config: IntlayerConfig = {
|
|
|
217
216
|
};
|
|
218
217
|
```
|
|
219
218
|
|
|
220
|
-
> For a complete list of available parameters, refer to the [configuration documentation](https://intlayer.org
|
|
219
|
+
> For a complete list of available parameters, refer to the [configuration documentation](https://intlayer.org/doc/concept/configuration).
|
|
221
220
|
|
|
222
221
|
Output:
|
|
223
222
|
|
|
@@ -256,7 +255,7 @@ Intlayer provides a CLI tool to:
|
|
|
256
255
|
- build dictionaries from your content declarations
|
|
257
256
|
- push and pull distant dictionaries from your CMS to your locale project
|
|
258
257
|
|
|
259
|
-
Consult [intlayer-cli](https://intlayer.org
|
|
258
|
+
Consult [intlayer-cli](https://intlayer.org/doc/concept/cli) for more information.
|
|
260
259
|
|
|
261
260
|
## Use Intlayer into your application
|
|
262
261
|
|
|
@@ -280,16 +279,16 @@ To use Intlayer in your Express application, you can use [express-intlayer](http
|
|
|
280
279
|
|
|
281
280
|
The `intlayer` package also provides some functions to help you to internationalize your application.
|
|
282
281
|
|
|
283
|
-
- [`getConfiguration()`](https://intlayer.org
|
|
284
|
-
- [`getTranslationContent()`](https://intlayer.org
|
|
285
|
-
- [`getEnumerationContent()`](https://intlayer.org
|
|
286
|
-
- [`getLocaleName()`](https://intlayer.org
|
|
287
|
-
- [`getLocaleLang()`](https://intlayer.org
|
|
288
|
-
- [`getHTMLTextDir()`](https://intlayer.org
|
|
289
|
-
- [`getPathWithoutLocale()`](https://intlayer.org
|
|
290
|
-
- [`getMultilingualUrls()`](https://intlayer.org
|
|
291
|
-
- [`getLocalizedUrl()`](https://intlayer.org
|
|
292
|
-
- [`getPathWithoutLocale()`](https://intlayer.org
|
|
282
|
+
- [`getConfiguration()`](https://intlayer.org/doc/packages/intlayer/getConfiguration)
|
|
283
|
+
- [`getTranslationContent()`](https://intlayer.org/doc/packages/intlayer/getTranslationContent)
|
|
284
|
+
- [`getEnumerationContent()`](https://intlayer.org/doc/packages/intlayer/getEnumerationContent)
|
|
285
|
+
- [`getLocaleName()`](https://intlayer.org/doc/packages/intlayer/getLocaleName)
|
|
286
|
+
- [`getLocaleLang()`](https://intlayer.org/doc/packages/intlayer/getLocaleLang)
|
|
287
|
+
- [`getHTMLTextDir()`](https://intlayer.org/doc/packages/intlayer/getHTMLTextDir)
|
|
288
|
+
- [`getPathWithoutLocale()`](https://intlayer.org/doc/packages/intlayer/getPathWithoutLocale)
|
|
289
|
+
- [`getMultilingualUrls()`](https://intlayer.org/doc/packages/intlayer/getMultilingualUrls)
|
|
290
|
+
- [`getLocalizedUrl()`](https://intlayer.org/doc/packages/intlayer/getLocalizedUrl)
|
|
291
|
+
- [`getPathWithoutLocale()`](https://intlayer.org/doc/packages/intlayer/getPathWithoutLocale)
|
|
293
292
|
|
|
294
293
|
## Read about Intlayer
|
|
295
294
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "intlayer",
|
|
3
|
-
"version": "4.1.
|
|
3
|
+
"version": "4.1.5",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Manage internationalization i18n in a simple way, through TypeScript, declaration file, declare your multilingual content every where in your code.",
|
|
6
6
|
"keywords": [
|
|
@@ -58,9 +58,9 @@
|
|
|
58
58
|
"./package.json"
|
|
59
59
|
],
|
|
60
60
|
"dependencies": {
|
|
61
|
-
"@intlayer/
|
|
62
|
-
"@intlayer/
|
|
63
|
-
"@intlayer/core": "^4.1.
|
|
61
|
+
"@intlayer/cli": "4.1.5",
|
|
62
|
+
"@intlayer/config": "4.1.5",
|
|
63
|
+
"@intlayer/core": "^4.1.5"
|
|
64
64
|
},
|
|
65
65
|
"devDependencies": {
|
|
66
66
|
"@changesets/changelog-github": "0.5.0",
|
|
@@ -74,15 +74,15 @@
|
|
|
74
74
|
"tsc-alias": "^1.8.10",
|
|
75
75
|
"tsup": "^8.3.5",
|
|
76
76
|
"typescript": "^5.7.3",
|
|
77
|
+
"@utils/eslint-config": "1.0.4",
|
|
77
78
|
"@utils/ts-config": "1.0.4",
|
|
78
79
|
"@utils/ts-config-types": "1.0.4",
|
|
79
|
-
"@utils/eslint-config": "1.0.4",
|
|
80
80
|
"@utils/tsup-config": "1.0.4"
|
|
81
81
|
},
|
|
82
82
|
"peerDependencies": {
|
|
83
|
-
"@intlayer/cli": "4.1.
|
|
84
|
-
"@intlayer/config": "4.1.
|
|
85
|
-
"@intlayer/core": "^4.1.
|
|
83
|
+
"@intlayer/cli": "4.1.5",
|
|
84
|
+
"@intlayer/config": "4.1.5",
|
|
85
|
+
"@intlayer/core": "^4.1.5"
|
|
86
86
|
},
|
|
87
87
|
"engines": {
|
|
88
88
|
"node": ">=14.18"
|