@intlayer/docs 7.5.10 → 7.5.12
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/blog/ar/intlayer_with_i18next.md +0 -2
- package/blog/ar/intlayer_with_next-i18next.md +0 -2
- package/blog/ar/intlayer_with_react-i18next.md +0 -2
- package/blog/de/intlayer_with_i18next.md +0 -45
- package/blog/de/intlayer_with_next-i18next.md +0 -46
- package/blog/de/intlayer_with_react-i18next.md +0 -2
- package/blog/en/intlayer_with_i18next.md +0 -46
- package/blog/en/intlayer_with_next-i18next.md +0 -48
- package/blog/en/intlayer_with_next-intl.md +0 -44
- package/blog/en/intlayer_with_react-i18next.md +0 -44
- package/blog/en/intlayer_with_react-intl.md +0 -42
- package/blog/en/intlayer_with_vue-i18n.md +0 -44
- package/blog/en-GB/intlayer_with_i18next.md +0 -45
- package/blog/en-GB/intlayer_with_next-i18next.md +0 -47
- package/blog/en-GB/intlayer_with_next-intl.md +0 -42
- package/blog/en-GB/intlayer_with_react-i18next.md +0 -43
- package/blog/en-GB/intlayer_with_react-intl.md +0 -42
- package/blog/en-GB/intlayer_with_vue-i18n.md +0 -46
- package/blog/es/intlayer_with_i18next.md +0 -45
- package/blog/es/intlayer_with_next-i18next.md +0 -47
- package/blog/es/intlayer_with_next-intl.md +0 -42
- package/blog/es/intlayer_with_react-i18next.md +0 -43
- package/blog/es/intlayer_with_react-intl.md +0 -42
- package/blog/es/intlayer_with_vue-i18n.md +0 -46
- package/blog/fr/intlayer_with_i18next.md +0 -45
- package/blog/fr/intlayer_with_next-i18next.md +0 -47
- package/blog/fr/intlayer_with_next-intl.md +0 -42
- package/blog/fr/intlayer_with_react-i18next.md +0 -43
- package/blog/fr/intlayer_with_react-intl.md +0 -42
- package/blog/fr/intlayer_with_vue-i18n.md +0 -46
- package/blog/hi/intlayer_with_i18next.md +0 -2
- package/blog/hi/intlayer_with_next-i18next.md +0 -2
- package/blog/hi/intlayer_with_react-i18next.md +0 -2
- package/blog/id/intlayer_with_i18next.md +0 -2
- package/blog/id/intlayer_with_next-i18next.md +0 -2
- package/blog/id/intlayer_with_react-i18next.md +0 -2
- package/blog/it/intlayer_with_i18next.md +0 -2
- package/blog/it/intlayer_with_next-i18next.md +0 -2
- package/blog/it/intlayer_with_react-i18next.md +0 -2
- package/blog/ja/intlayer_with_i18next.md +0 -45
- package/blog/ja/intlayer_with_next-i18next.md +0 -46
- package/blog/ja/intlayer_with_next-intl.md +0 -42
- package/blog/ja/intlayer_with_react-i18next.md +0 -42
- package/blog/ja/intlayer_with_react-intl.md +0 -42
- package/blog/ja/intlayer_with_vue-i18n.md +0 -46
- package/blog/ko/intlayer_with_i18next.md +0 -2
- package/blog/ko/intlayer_with_next-i18next.md +0 -2
- package/blog/ko/intlayer_with_react-i18next.md +0 -1
- package/blog/pl/intlayer_with_i18next.md +0 -45
- package/blog/pl/intlayer_with_next-i18next.md +0 -46
- package/blog/pl/intlayer_with_next-intl.md +0 -42
- package/blog/pl/intlayer_with_react-i18next.md +0 -43
- package/blog/pl/intlayer_with_react-intl.md +0 -42
- package/blog/pl/intlayer_with_vue-i18n.md +0 -46
- package/blog/pt/intlayer_with_i18next.md +0 -2
- package/blog/pt/intlayer_with_next-i18next.md +0 -2
- package/blog/pt/intlayer_with_react-i18next.md +0 -2
- package/blog/ru/intlayer_with_i18next.md +0 -45
- package/blog/ru/intlayer_with_next-i18next.md +0 -47
- package/blog/ru/intlayer_with_next-intl.md +0 -42
- package/blog/ru/intlayer_with_react-i18next.md +0 -43
- package/blog/ru/intlayer_with_react-intl.md +0 -42
- package/blog/ru/intlayer_with_vue-i18n.md +0 -46
- package/blog/tr/intlayer_with_i18next.md +0 -2
- package/blog/tr/intlayer_with_next-i18next.md +0 -1
- package/blog/tr/intlayer_with_react-i18next.md +0 -2
- package/blog/vi/intlayer_with_i18next.md +0 -2
- package/blog/vi/intlayer_with_next-i18next.md +0 -2
- package/blog/vi/intlayer_with_react-i18next.md +0 -2
- package/blog/zh/intlayer_with_i18next.md +0 -2
- package/blog/zh/intlayer_with_next-i18next.md +0 -2
- package/blog/zh/intlayer_with_react-i18next.md +0 -2
- package/blog/zh/intlayer_with_vue-i18n.md +0 -46
- package/dist/cjs/generated/blog.entry.cjs +58 -29
- package/dist/cjs/generated/blog.entry.cjs.map +1 -1
- package/dist/cjs/generated/docs.entry.cjs +254 -97
- package/dist/cjs/generated/docs.entry.cjs.map +1 -1
- package/dist/cjs/generated/frequentQuestions.entry.cjs +30 -15
- package/dist/cjs/generated/frequentQuestions.entry.cjs.map +1 -1
- package/dist/cjs/generated/legal.entry.cjs +4 -2
- package/dist/cjs/generated/legal.entry.cjs.map +1 -1
- package/dist/esm/generated/blog.entry.mjs +58 -29
- package/dist/esm/generated/blog.entry.mjs.map +1 -1
- package/dist/esm/generated/docs.entry.mjs +254 -97
- package/dist/esm/generated/docs.entry.mjs.map +1 -1
- package/dist/esm/generated/frequentQuestions.entry.mjs +30 -15
- package/dist/esm/generated/frequentQuestions.entry.mjs.map +1 -1
- package/dist/esm/generated/legal.entry.mjs +4 -2
- package/dist/esm/generated/legal.entry.mjs.map +1 -1
- package/dist/types/generated/blog.entry.d.ts.map +1 -1
- package/dist/types/generated/docs.entry.d.ts +3 -0
- package/dist/types/generated/docs.entry.d.ts.map +1 -1
- package/dist/types/generated/frequentQuestions.entry.d.ts.map +1 -1
- package/dist/types/generated/legal.entry.d.ts.map +1 -1
- package/docs/ar/cli/ci.md +137 -0
- package/docs/ar/cli/index.md +7 -1
- package/docs/ar/cli/list.md +39 -2
- package/docs/ar/cli/list_projects.md +131 -0
- package/docs/ar/intlayer_CMS.md +20 -0
- package/docs/ar/intlayer_with_next-i18next.md +0 -1
- package/docs/ar/intlayer_with_nextjs_14.md +28 -0
- package/docs/ar/intlayer_with_nextjs_15.md +28 -0
- package/docs/ar/intlayer_with_nextjs_16.md +28 -0
- package/docs/ar/intlayer_with_nextjs_no_locale_path.md +1159 -0
- package/docs/ar/plugins/sync-json.md +6 -2
- package/docs/de/cli/ci.md +137 -0
- package/docs/de/cli/index.md +7 -1
- package/docs/de/cli/list.md +39 -2
- package/docs/de/cli/list_projects.md +130 -0
- package/docs/de/intlayer_CMS.md +20 -0
- package/docs/de/intlayer_with_next-i18next.md +0 -1
- package/docs/de/intlayer_with_nextjs_14.md +28 -0
- package/docs/de/intlayer_with_nextjs_15.md +28 -0
- package/docs/de/intlayer_with_nextjs_16.md +28 -0
- package/docs/de/intlayer_with_nextjs_no_locale_path.md +1152 -0
- package/docs/de/plugins/sync-json.md +6 -2
- package/docs/en/cli/ci.md +137 -0
- package/docs/en/cli/index.md +14 -1
- package/docs/en/cli/list.md +39 -2
- package/docs/en/cli/list_projects.md +128 -0
- package/docs/en/interest_of_intlayer.md +1 -1
- package/docs/en/intlayer_CMS.md +20 -0
- package/docs/en/intlayer_with_next-i18next.md +0 -1
- package/docs/en/intlayer_with_nextjs_14.md +28 -0
- package/docs/en/intlayer_with_nextjs_15.md +28 -0
- package/docs/en/intlayer_with_nextjs_16.md +31 -1
- package/docs/en/intlayer_with_nextjs_no_locale_path.md +1132 -0
- package/docs/en/plugins/sync-json.md +6 -2
- package/docs/en-GB/cli/ci.md +137 -0
- package/docs/en-GB/cli/index.md +7 -1
- package/docs/en-GB/cli/list.md +39 -2
- package/docs/en-GB/cli/list_projects.md +130 -0
- package/docs/en-GB/intlayer_CMS.md +20 -0
- package/docs/en-GB/intlayer_with_next-i18next.md +0 -1
- package/docs/en-GB/intlayer_with_nextjs_14.md +28 -0
- package/docs/en-GB/intlayer_with_nextjs_15.md +28 -0
- package/docs/en-GB/intlayer_with_nextjs_16.md +28 -0
- package/docs/en-GB/intlayer_with_nextjs_no_locale_path.md +1154 -0
- package/docs/en-GB/plugins/sync-json.md +6 -2
- package/docs/es/cli/ci.md +137 -0
- package/docs/es/cli/index.md +7 -1
- package/docs/es/cli/list.md +39 -2
- package/docs/es/cli/list_projects.md +130 -0
- package/docs/es/intlayer_CMS.md +20 -0
- package/docs/es/intlayer_with_next-i18next.md +0 -1
- package/docs/es/intlayer_with_nextjs_14.md +28 -0
- package/docs/es/intlayer_with_nextjs_15.md +28 -0
- package/docs/es/intlayer_with_nextjs_16.md +28 -0
- package/docs/es/intlayer_with_nextjs_no_locale_path.md +1143 -0
- package/docs/es/plugins/sync-json.md +6 -2
- package/docs/fr/cli/ci.md +137 -0
- package/docs/fr/cli/index.md +7 -1
- package/docs/fr/cli/list.md +39 -2
- package/docs/fr/cli/list_projects.md +131 -0
- package/docs/fr/intlayer_CMS.md +20 -0
- package/docs/fr/intlayer_with_next-i18next.md +0 -1
- package/docs/fr/intlayer_with_nextjs_14.md +28 -0
- package/docs/fr/intlayer_with_nextjs_15.md +28 -0
- package/docs/fr/intlayer_with_nextjs_16.md +28 -0
- package/docs/fr/intlayer_with_nextjs_no_locale_path.md +1174 -0
- package/docs/fr/plugins/sync-json.md +9 -5
- package/docs/hi/cli/ci.md +137 -0
- package/docs/hi/cli/index.md +7 -1
- package/docs/hi/cli/list.md +38 -1
- package/docs/hi/cli/list_projects.md +130 -0
- package/docs/hi/intlayer_CMS.md +20 -0
- package/docs/hi/intlayer_with_next-i18next.md +0 -1
- package/docs/hi/intlayer_with_nextjs_14.md +28 -0
- package/docs/hi/intlayer_with_nextjs_15.md +28 -0
- package/docs/hi/intlayer_with_nextjs_16.md +28 -0
- package/docs/hi/intlayer_with_nextjs_no_locale_path.md +1151 -0
- package/docs/hi/plugins/sync-json.md +6 -2
- package/docs/id/cli/ci.md +137 -0
- package/docs/id/cli/index.md +7 -1
- package/docs/id/cli/list.md +38 -1
- package/docs/id/cli/list_projects.md +128 -0
- package/docs/id/intlayer_CMS.md +20 -0
- package/docs/id/intlayer_with_next-i18next.md +0 -1
- package/docs/id/intlayer_with_nextjs_14.md +28 -0
- package/docs/id/intlayer_with_nextjs_15.md +28 -0
- package/docs/id/intlayer_with_nextjs_16.md +28 -0
- package/docs/id/intlayer_with_nextjs_no_locale_path.md +1154 -0
- package/docs/id/plugins/sync-json.md +6 -2
- package/docs/it/cli/ci.md +137 -0
- package/docs/it/cli/index.md +7 -1
- package/docs/it/cli/list.md +39 -2
- package/docs/it/cli/list_projects.md +130 -0
- package/docs/it/intlayer_CMS.md +20 -0
- package/docs/it/intlayer_with_next-i18next.md +0 -1
- package/docs/it/intlayer_with_nextjs_14.md +28 -0
- package/docs/it/intlayer_with_nextjs_15.md +28 -0
- package/docs/it/intlayer_with_nextjs_16.md +28 -0
- package/docs/it/intlayer_with_nextjs_no_locale_path.md +1148 -0
- package/docs/it/plugins/sync-json.md +6 -2
- package/docs/ja/cli/ci.md +137 -0
- package/docs/ja/cli/index.md +7 -1
- package/docs/ja/cli/list.md +38 -1
- package/docs/ja/cli/list_projects.md +136 -0
- package/docs/ja/intlayer_CMS.md +20 -0
- package/docs/ja/intlayer_with_next-i18next.md +0 -1
- package/docs/ja/intlayer_with_nextjs_14.md +28 -0
- package/docs/ja/intlayer_with_nextjs_15.md +28 -0
- package/docs/ja/intlayer_with_nextjs_16.md +28 -0
- package/docs/ja/intlayer_with_nextjs_no_locale_path.md +1222 -0
- package/docs/ja/plugins/sync-json.md +6 -2
- package/docs/ko/cli/ci.md +137 -0
- package/docs/ko/cli/index.md +7 -1
- package/docs/ko/cli/list.md +38 -1
- package/docs/ko/cli/list_projects.md +128 -0
- package/docs/ko/intlayer_CMS.md +20 -0
- package/docs/ko/intlayer_with_next-i18next.md +0 -1
- package/docs/ko/intlayer_with_nextjs_14.md +28 -0
- package/docs/ko/intlayer_with_nextjs_15.md +28 -0
- package/docs/ko/intlayer_with_nextjs_16.md +28 -0
- package/docs/ko/intlayer_with_nextjs_no_locale_path.md +1205 -0
- package/docs/ko/plugins/sync-json.md +6 -2
- package/docs/pl/cli/ci.md +137 -0
- package/docs/pl/cli/index.md +7 -1
- package/docs/pl/cli/list.md +39 -2
- package/docs/pl/cli/list_projects.md +130 -0
- package/docs/pl/intlayer_CMS.md +20 -0
- package/docs/pl/intlayer_with_next-i18next.md +0 -1
- package/docs/pl/intlayer_with_nextjs_14.md +28 -0
- package/docs/pl/intlayer_with_nextjs_15.md +28 -0
- package/docs/pl/intlayer_with_nextjs_16.md +28 -0
- package/docs/pl/intlayer_with_nextjs_no_locale_path.md +1149 -0
- package/docs/pl/plugins/sync-json.md +6 -2
- package/docs/pt/cli/ci.md +137 -0
- package/docs/pt/cli/index.md +7 -1
- package/docs/pt/cli/list.md +39 -2
- package/docs/pt/cli/list_projects.md +134 -0
- package/docs/pt/intlayer_CMS.md +20 -0
- package/docs/pt/intlayer_with_next-i18next.md +0 -1
- package/docs/pt/intlayer_with_nextjs_14.md +28 -0
- package/docs/pt/intlayer_with_nextjs_15.md +28 -0
- package/docs/pt/intlayer_with_nextjs_16.md +28 -0
- package/docs/pt/intlayer_with_nextjs_no_locale_path.md +1152 -0
- package/docs/pt/plugins/sync-json.md +6 -2
- package/docs/ru/cli/ci.md +137 -0
- package/docs/ru/cli/index.md +7 -1
- package/docs/ru/cli/list.md +39 -2
- package/docs/ru/cli/list_projects.md +130 -0
- package/docs/ru/intlayer_CMS.md +20 -0
- package/docs/ru/intlayer_with_next-i18next.md +0 -1
- package/docs/ru/intlayer_with_nextjs_14.md +28 -0
- package/docs/ru/intlayer_with_nextjs_15.md +28 -0
- package/docs/ru/intlayer_with_nextjs_16.md +28 -0
- package/docs/ru/intlayer_with_nextjs_no_locale_path.md +1204 -0
- package/docs/ru/plugins/sync-json.md +6 -2
- package/docs/tr/cli/ci.md +137 -0
- package/docs/tr/cli/index.md +7 -1
- package/docs/tr/cli/list.md +39 -2
- package/docs/tr/cli/list_projects.md +134 -0
- package/docs/tr/intlayer_CMS.md +20 -0
- package/docs/tr/intlayer_with_next-i18next.md +0 -1
- package/docs/tr/intlayer_with_nextjs_14.md +28 -0
- package/docs/tr/intlayer_with_nextjs_15.md +28 -0
- package/docs/tr/intlayer_with_nextjs_16.md +28 -0
- package/docs/tr/intlayer_with_nextjs_no_locale_path.md +1159 -0
- package/docs/tr/plugins/sync-json.md +6 -2
- package/docs/uk/compiler.md +133 -0
- package/docs/uk/component_i18n.md +194 -0
- package/docs/uk/intlayer_with_nextjs_14.md +1646 -0
- package/docs/uk/intlayer_with_nextjs_15.md +1910 -0
- package/docs/uk/intlayer_with_nextjs_16.md +1763 -0
- package/docs/uk/intlayer_with_nextjs_no_locale_path.md +1159 -0
- package/docs/uk/intlayer_with_react_native+expo.md +715 -0
- package/docs/uk/packages/intlayer/getConfiguration.md +145 -0
- package/docs/uk/vs_code_extension.md +133 -0
- package/docs/vi/cli/ci.md +137 -0
- package/docs/vi/cli/index.md +7 -1
- package/docs/vi/cli/list.md +38 -1
- package/docs/vi/cli/list_projects.md +130 -0
- package/docs/vi/intlayer_CMS.md +20 -0
- package/docs/vi/intlayer_with_next-i18next.md +0 -1
- package/docs/vi/intlayer_with_nextjs_14.md +28 -0
- package/docs/vi/intlayer_with_nextjs_15.md +28 -0
- package/docs/vi/intlayer_with_nextjs_16.md +28 -0
- package/docs/vi/intlayer_with_nextjs_no_locale_path.md +1151 -0
- package/docs/vi/plugins/sync-json.md +6 -2
- package/docs/zh/cli/ci.md +137 -0
- package/docs/zh/cli/index.md +7 -1
- package/docs/zh/cli/list.md +38 -1
- package/docs/zh/cli/list_projects.md +130 -0
- package/docs/zh/intlayer_CMS.md +20 -0
- package/docs/zh/intlayer_with_next-i18next.md +0 -1
- package/docs/zh/intlayer_with_nextjs_14.md +28 -0
- package/docs/zh/intlayer_with_nextjs_15.md +28 -0
- package/docs/zh/intlayer_with_nextjs_16.md +28 -0
- package/docs/zh/intlayer_with_nextjs_no_locale_path.md +1206 -0
- package/docs/zh/plugins/sync-json.md +9 -5
- package/frequent_questions/ar/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/de/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/en/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/en-GB/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/es/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/fr/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/hi/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/id/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/it/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/ja/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/ko/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/pl/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/pt/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/ru/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/tr/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/vi/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/zh/SSR_Next_no_[locale].md +1 -1
- package/package.json +6 -6
- package/src/generated/blog.entry.ts +29 -0
- package/src/generated/docs.entry.ts +157 -0
- package/src/generated/frequentQuestions.entry.ts +15 -0
- package/src/generated/legal.entry.ts +2 -0
|
@@ -108,18 +108,22 @@ syncJSON({
|
|
|
108
108
|
source: ({ key, locale }) => string, // requerido
|
|
109
109
|
location?: string, // etiqueta opcional, por defecto: "plugin"
|
|
110
110
|
priority?: number, // prioridad opcional para resolución de conflictos, por defecto: 0
|
|
111
|
-
format?: 'intlayer' | 'icu' | 'i18next', // formateador opcional,
|
|
111
|
+
format?: 'intlayer' | 'icu' | 'i18next', // formateador opcional, usado para compatibilidad con el runtime de Intlayer
|
|
112
112
|
});
|
|
113
113
|
```
|
|
114
114
|
|
|
115
115
|
#### `format` ('intlayer' | 'icu' | 'i18next')
|
|
116
116
|
|
|
117
|
-
Especifica el formateador a utilizar para el contenido del diccionario al sincronizar archivos JSON. Esto permite usar diferentes sintaxis de formateo de mensajes compatibles con
|
|
117
|
+
Especifica el formateador a utilizar para el contenido del diccionario al sincronizar archivos JSON. Esto permite usar diferentes sintaxis de formateo de mensajes compatibles con el runtime de Intlayer.
|
|
118
118
|
|
|
119
|
+
- `undefined`: No se usará ningún formateador, el contenido JSON se usará tal cual.
|
|
119
120
|
- `'intlayer'`: El formateador Intlayer por defecto (por defecto).
|
|
120
121
|
- `'icu'`: Usa el formateo de mensajes ICU (compatible con bibliotecas como react-intl, vue-i18n).
|
|
121
122
|
- `'i18next'`: Usa el formateo de mensajes i18next (compatible con i18next, next-i18next, Solid-i18next).
|
|
122
123
|
|
|
124
|
+
> Ten en cuenta que usar un formateador transformará tu contenido JSON en entrada y salida. Para reglas JSON complejas como plurales ICU, el parsing puede no garantizar un mapeo 1 a 1 entre entrada y salida.
|
|
125
|
+
> Si no usas el runtime de Intlayer, podrías preferir no establecer un formateador.
|
|
126
|
+
|
|
123
127
|
**Ejemplo:**
|
|
124
128
|
|
|
125
129
|
```ts
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
---
|
|
2
|
+
createdAt: 2026-01-06
|
|
3
|
+
updatedAt: 2026-01-06
|
|
4
|
+
title: Commande CI
|
|
5
|
+
description: Apprenez à utiliser la commande Intlayer CI pour exécuter des commandes Intlayer avec des identifiants auto-injectés dans les pipelines CI/CD et les monorepos.
|
|
6
|
+
keywords:
|
|
7
|
+
- CI
|
|
8
|
+
- CI/CD
|
|
9
|
+
- Automatisation
|
|
10
|
+
- Monorepo
|
|
11
|
+
- Identifiants
|
|
12
|
+
- CLI
|
|
13
|
+
- Intlayer
|
|
14
|
+
slugs:
|
|
15
|
+
- doc
|
|
16
|
+
- concept
|
|
17
|
+
- cli
|
|
18
|
+
- ci
|
|
19
|
+
history:
|
|
20
|
+
- version: 7.5.11
|
|
21
|
+
date: 2026-01-06
|
|
22
|
+
changes: Ajouter la commande CI
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
# Commande CI
|
|
26
|
+
|
|
27
|
+
```bash
|
|
28
|
+
npx intlayer ci <command...>
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
La commande CI est conçue pour l'automatisation et les pipelines CI/CD. Elle injecte automatiquement les identifiants à partir de la variable d'environnement `INTLAYER_PROJECT_CREDENTIALS` et peut exécuter des commandes Intlayer sur plusieurs projets dans un monorepo.
|
|
32
|
+
|
|
33
|
+
## Fonctionnement
|
|
34
|
+
|
|
35
|
+
La commande CI fonctionne en deux modes :
|
|
36
|
+
|
|
37
|
+
1. **Mode projet unique** : Si le répertoire de travail actuel correspond à l'un des chemins de projet dans `INTLAYER_PROJECT_CREDENTIALS`, elle exécute la commande uniquement pour ce projet spécifique.
|
|
38
|
+
|
|
39
|
+
2. **Mode itération** : Si aucun contexte de projet spécifique n'est détecté, elle itère sur tous les projets configurés et exécute la commande pour chacun d'eux.
|
|
40
|
+
|
|
41
|
+
## Variable d'environnement
|
|
42
|
+
|
|
43
|
+
La commande nécessite que la variable d'environnement `INTLAYER_PROJECT_CREDENTIALS` soit définie. Cette variable doit contenir un objet JSON mappant les chemins de projet à leurs identifiants :
|
|
44
|
+
|
|
45
|
+
```json
|
|
46
|
+
{
|
|
47
|
+
"packages/app": {
|
|
48
|
+
"clientId": "your-client-id-1",
|
|
49
|
+
"clientSecret": "your-client-secret-1"
|
|
50
|
+
},
|
|
51
|
+
"packages/admin": {
|
|
52
|
+
"clientId": "your-client-id-2",
|
|
53
|
+
"clientSecret": "your-client-secret-2"
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
## Détection du gestionnaire de paquets
|
|
59
|
+
|
|
60
|
+
La commande CI détecte automatiquement le gestionnaire de paquets utilisé (npm, yarn, pnpm ou bun) en fonction de la variable d'environnement `npm_config_user_agent` et utilise la commande appropriée pour exécuter Intlayer.
|
|
61
|
+
|
|
62
|
+
## Arguments
|
|
63
|
+
|
|
64
|
+
- **`<command...>`** : La commande Intlayer à exécuter (par exemple, `fill`, `push`, `build`). Vous pouvez passer n'importe quelle commande Intlayer et ses arguments.
|
|
65
|
+
|
|
66
|
+
> Exemple : `npx intlayer ci fill --verbose`
|
|
67
|
+
>
|
|
68
|
+
> Exemple : `npx intlayer ci push`
|
|
69
|
+
>
|
|
70
|
+
> Exemple : `npx intlayer ci build`
|
|
71
|
+
|
|
72
|
+
## Exemples
|
|
73
|
+
|
|
74
|
+
### Exécuter une commande en mode projet unique
|
|
75
|
+
|
|
76
|
+
Si vous êtes dans un répertoire de projet qui correspond à l'un des chemins dans `INTLAYER_PROJECT_CREDENTIALS` :
|
|
77
|
+
|
|
78
|
+
```bash
|
|
79
|
+
cd packages/app
|
|
80
|
+
npx intlayer ci fill
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
Cela exécutera la commande `fill` avec les identifiants automatiquement injectés pour le projet `packages/app`.
|
|
84
|
+
|
|
85
|
+
### Exécuter une commande sur tous les projets
|
|
86
|
+
|
|
87
|
+
Si vous êtes dans un répertoire qui ne correspond à aucun chemin de projet, la commande itérera sur tous les projets configurés :
|
|
88
|
+
|
|
89
|
+
```bash
|
|
90
|
+
cd /path/to/monorepo
|
|
91
|
+
npx intlayer ci push
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
Cela exécutera la commande `push` pour chaque projet configuré dans `INTLAYER_PROJECT_CREDENTIALS`.
|
|
95
|
+
|
|
96
|
+
### Passer des drapeaux supplémentaires
|
|
97
|
+
|
|
98
|
+
Vous pouvez passer n'importe quels drapeaux à la commande Intlayer sous-jacente :
|
|
99
|
+
|
|
100
|
+
```bash
|
|
101
|
+
npx intlayer ci fill --verbose --mode complete
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
### Utilisation dans les pipelines CI/CD
|
|
105
|
+
|
|
106
|
+
Dans votre configuration CI/CD (par exemple, GitHub Actions, GitLab CI), définissez `INTLAYER_PROJECT_CREDENTIALS` comme secret :
|
|
107
|
+
|
|
108
|
+
```yaml
|
|
109
|
+
# Exemple GitHub Actions
|
|
110
|
+
env:
|
|
111
|
+
INTLAYER_PROJECT_CREDENTIALS: ${{ secrets.INTLAYER_PROJECT_CREDENTIALS }}
|
|
112
|
+
|
|
113
|
+
steps:
|
|
114
|
+
- name: Remplir les dictionnaires
|
|
115
|
+
run: npx intlayer ci fill
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
## Gestion des erreurs
|
|
119
|
+
|
|
120
|
+
- Si `INTLAYER_PROJECT_CREDENTIALS` n'est pas définie, la commande se terminera avec une erreur.
|
|
121
|
+
- Si `INTLAYER_PROJECT_CREDENTIALS` n'est pas un JSON valide, la commande se terminera avec une erreur.
|
|
122
|
+
- Si un chemin de projet n'existe pas, il sera ignoré avec un avertissement.
|
|
123
|
+
- Si un projet échoue, la commande se terminera avec un code de statut non nul.
|
|
124
|
+
|
|
125
|
+
## Cas d'utilisation
|
|
126
|
+
|
|
127
|
+
- **Automatisation de monorepo** : Exécuter des commandes Intlayer sur plusieurs projets dans un monorepo
|
|
128
|
+
- **Pipelines CI/CD** : Automatiser la gestion des dictionnaires dans les workflows d'intégration continue
|
|
129
|
+
- **Opérations en masse** : Effectuer la même opération sur plusieurs projets Intlayer à la fois
|
|
130
|
+
- **Gestion des secrets** : Gérer de manière sécurisée les identifiants pour plusieurs projets en utilisant des variables d'environnement
|
|
131
|
+
|
|
132
|
+
## Bonnes pratiques de sécurité
|
|
133
|
+
|
|
134
|
+
- Stockez `INTLAYER_PROJECT_CREDENTIALS` comme secrets chiffrés dans votre plateforme CI/CD
|
|
135
|
+
- Ne commitez jamais les identifiants dans le contrôle de version
|
|
136
|
+
- Utilisez des identifiants spécifiques à l'environnement pour différents environnements de déploiement
|
|
137
|
+
- Faites tourner les identifiants régulièrement
|
package/docs/fr/cli/index.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
createdAt: 2024-08-11
|
|
3
|
-
updatedAt:
|
|
3
|
+
updatedAt: 2026-01-06
|
|
4
4
|
title: CLI
|
|
5
5
|
description: Découvrez comment utiliser le CLI Intlayer pour gérer votre site web multilingue. Suivez les étapes de cette documentation en ligne pour configurer votre projet en quelques minutes.
|
|
6
6
|
keywords:
|
|
@@ -17,6 +17,9 @@ slugs:
|
|
|
17
17
|
- concept
|
|
18
18
|
- cli
|
|
19
19
|
history:
|
|
20
|
+
- version: 7.5.11
|
|
21
|
+
date: 2026-01-06
|
|
22
|
+
changes: Ajout de la commande projects list
|
|
20
23
|
- version: 7.5.9
|
|
21
24
|
date: 2025-12-30
|
|
22
25
|
changes: Ajout de la commande init
|
|
@@ -119,6 +122,7 @@ Pour voir comment configurer les locales disponibles, ou d'autres paramètres, r
|
|
|
119
122
|
- **[Construire les dictionnaires](https://github.com/aymericzip/intlayer/blob/main/docs/docs/fr/cli/build.md)** - Construisez vos dictionnaires à partir des fichiers de déclaration de contenu
|
|
120
123
|
- **[Surveiller les dictionnaires](https://github.com/aymericzip/intlayer/blob/main/docs/docs/fr/cli/watch.md)** - Surveillez les changements et construisez automatiquement les dictionnaires
|
|
121
124
|
- **[Vérifier la version CLI](https://github.com/aymericzip/intlayer/blob/main/docs/docs/fr/cli/version.md)** - Vérifiez la version installée de la CLI Intlayer
|
|
125
|
+
- **[Lister les projets](https://github.com/aymericzip/intlayer/blob/main/docs/docs/fr/cli/list_projects.md)** - Listez tous les projets Intlayer dans un répertoire ou un dépôt git
|
|
122
126
|
|
|
123
127
|
### Gestion des dictionnaires
|
|
124
128
|
|
|
@@ -166,6 +170,7 @@ Pour voir comment configurer les locales disponibles, ou d'autres paramètres, r
|
|
|
166
170
|
"intlayer:list": "npx intlayer content list",
|
|
167
171
|
"intlayer:test": "npx intlayer content test",
|
|
168
172
|
"intlayer:transform": "npx intlayer transform",
|
|
173
|
+
"intlayer:projects": "npx intlayer projects list",
|
|
169
174
|
"intlayer:doc:translate": "npx intlayer doc translate",
|
|
170
175
|
"intlayer:doc:review": "npx intlayer doc review"
|
|
171
176
|
}
|
|
@@ -175,3 +180,4 @@ Pour voir comment configurer les locales disponibles, ou d'autres paramètres, r
|
|
|
175
180
|
>
|
|
176
181
|
> - `npx intlayer list` au lieu de `npx intlayer content list`
|
|
177
182
|
> - `npx intlayer test` au lieu de `npx intlayer content test`
|
|
183
|
+
> - `npx intlayer projects-list` ou `npx intlayer pl` au lieu de `npx intlayer projects list`
|
package/docs/fr/cli/list.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
createdAt: 2024-08-11
|
|
3
|
-
updatedAt:
|
|
3
|
+
updatedAt: 2026-01-06
|
|
4
4
|
title: Lister les fichiers de déclaration de contenu
|
|
5
5
|
description: Apprenez à lister tous les fichiers de déclaration de contenu dans votre projet.
|
|
6
6
|
keywords:
|
|
@@ -13,6 +13,13 @@ slugs:
|
|
|
13
13
|
- concept
|
|
14
14
|
- cli
|
|
15
15
|
- list
|
|
16
|
+
history:
|
|
17
|
+
- version: 7.5.12
|
|
18
|
+
date: 2026-01-06
|
|
19
|
+
changes: Ajouter l'option de sortie absolue à la commande list
|
|
20
|
+
- version: 7.5.11
|
|
21
|
+
date: 2026-01-06
|
|
22
|
+
changes: Ajouter l'option de sortie JSON à la commande list
|
|
16
23
|
---
|
|
17
24
|
|
|
18
25
|
# Lister les fichiers de déclaration de contenu
|
|
@@ -27,14 +34,36 @@ npx intlayer content list
|
|
|
27
34
|
|
|
28
35
|
Cette commande affiche tous les fichiers de déclaration de contenu dans votre projet, en montrant leurs clés de dictionnaire et leurs chemins de fichiers. Elle est utile pour obtenir une vue d'ensemble de tous vos fichiers de contenu et vérifier qu'ils sont correctement découverts par Intlayer.
|
|
29
36
|
|
|
30
|
-
##
|
|
37
|
+
## Arguments :
|
|
38
|
+
|
|
39
|
+
- **`--json`** : Affiche les résultats au format JSON au lieu de texte formaté. Utile pour le scripting et l'accès programmatique.
|
|
40
|
+
|
|
41
|
+
> Exemple : `npx intlayer content list --json`
|
|
42
|
+
|
|
43
|
+
## Exemples :
|
|
44
|
+
|
|
45
|
+
### Lister les fichiers de déclaration de contenu :
|
|
31
46
|
|
|
32
47
|
```bash
|
|
33
48
|
npx intlayer content list
|
|
34
49
|
```
|
|
35
50
|
|
|
51
|
+
### Sortie au format JSON :
|
|
52
|
+
|
|
53
|
+
```bash
|
|
54
|
+
npx intlayer content list --json
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
### Sortie en tant que chemins absolus :
|
|
58
|
+
|
|
59
|
+
```bash
|
|
60
|
+
npx intlayer content list --absolute
|
|
61
|
+
```
|
|
62
|
+
|
|
36
63
|
## Exemple de sortie :
|
|
37
64
|
|
|
65
|
+
### Sortie formatée :
|
|
66
|
+
|
|
38
67
|
```bash
|
|
39
68
|
npx intlayer content list
|
|
40
69
|
Fichiers de déclaration de contenu :
|
|
@@ -45,6 +74,14 @@ Fichiers de déclaration de contenu :
|
|
|
45
74
|
Nombre total de fichiers de déclaration de contenu : 3
|
|
46
75
|
```
|
|
47
76
|
|
|
77
|
+
### Sortie JSON :
|
|
78
|
+
|
|
79
|
+
```bash
|
|
80
|
+
$ npx intlayer content list --json
|
|
81
|
+
|
|
82
|
+
[{"key":"home-page","path":"src/components/HomePage/homePage.content.ts"},{"key":"server-component","path":"src/components/ServerComponent/serverComponent.content.ts"},{"key":"client-component","path":"src/components/ClientComponent/clientComponent.content.ts"}]
|
|
83
|
+
```
|
|
84
|
+
|
|
48
85
|
Cette commande affichera :
|
|
49
86
|
|
|
50
87
|
- Une liste formatée de tous les fichiers de déclaration de contenu avec leurs clés et chemins de fichiers relatifs
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
---
|
|
2
|
+
createdAt: 2025-12-30
|
|
3
|
+
updatedAt: 2026-01-06
|
|
4
|
+
title: Lister les projets Intlayer
|
|
5
|
+
description: Apprenez comment lister tous les projets Intlayer dans un répertoire ou un dépôt git.
|
|
6
|
+
keywords:
|
|
7
|
+
- Liste
|
|
8
|
+
- Projets
|
|
9
|
+
- CLI
|
|
10
|
+
- Intlayer
|
|
11
|
+
- Git
|
|
12
|
+
slugs:
|
|
13
|
+
- doc
|
|
14
|
+
- concept
|
|
15
|
+
- cli
|
|
16
|
+
- list-projects
|
|
17
|
+
history:
|
|
18
|
+
- version: 7.5.12
|
|
19
|
+
date: 2026-01-06
|
|
20
|
+
changes: Ajouter l'option de sortie absolue à la commande list projects
|
|
21
|
+
---
|
|
22
|
+
|
|
23
|
+
# Lister les projets Intlayer
|
|
24
|
+
|
|
25
|
+
```bash
|
|
26
|
+
npx intlayer projects list
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
Cette commande recherche et liste tous les projets Intlayer en trouvant les répertoires qui contiennent des fichiers de configuration Intlayer. Elle est utile pour découvrir tous les projets Intlayer dans un monorepo, un workspace ou un dépôt git.
|
|
30
|
+
|
|
31
|
+
## Alias :
|
|
32
|
+
|
|
33
|
+
- `npx intlayer projects-list`
|
|
34
|
+
- `npx intlayer pl`
|
|
35
|
+
|
|
36
|
+
## Arguments :
|
|
37
|
+
|
|
38
|
+
- **`--base-dir [path]`** : Spécifiez le répertoire de base à partir duquel effectuer la recherche. Par défaut, le répertoire de travail courant est utilisé.
|
|
39
|
+
|
|
40
|
+
> Exemple : `npx intlayer projects list --base-dir /path/to/workspace`
|
|
41
|
+
|
|
42
|
+
> Exemple : `npx intlayer projects list --base-dir /path/to/workspace`
|
|
43
|
+
|
|
44
|
+
- **`--git-root`** : Rechercher à partir du répertoire racine git au lieu du répertoire de base. Ceci est utile pour trouver tous les projets Intlayer dans un monorepo ou un dépôt git.
|
|
45
|
+
|
|
46
|
+
> Exemple : `npx intlayer projects list --git-root`
|
|
47
|
+
|
|
48
|
+
- **`--json`** : Affiche les résultats au format JSON au lieu de texte formaté. Utile pour le scripting et l'accès programmatique.
|
|
49
|
+
|
|
50
|
+
> Exemple : `npx intlayer projects list --json`
|
|
51
|
+
|
|
52
|
+
- **`--absolute`** : Affiche les résultats en tant que chemins absolus au lieu de chemins relatifs.
|
|
53
|
+
|
|
54
|
+
> Exemple : `npx intlayer projects list --absolute`
|
|
55
|
+
|
|
56
|
+
## Comment ça fonctionne :
|
|
57
|
+
|
|
58
|
+
La commande recherche les fichiers de configuration Intlayer dans le répertoire spécifié (ou la racine git si `--git-root` est utilisé). Elle recherche les modèles de fichiers de configuration suivants :
|
|
59
|
+
|
|
60
|
+
- `intlayer.config.ts`
|
|
61
|
+
- `intlayer.config.js`
|
|
62
|
+
- `intlayer.config.json`
|
|
63
|
+
- `intlayer.config.cjs`
|
|
64
|
+
- `intlayer.config.mjs`
|
|
65
|
+
- `.intlayerrc`
|
|
66
|
+
|
|
67
|
+
Chaque répertoire contenant un de ces fichiers est considéré comme un projet Intlayer et sera listé dans la sortie.
|
|
68
|
+
|
|
69
|
+
## Exemples :
|
|
70
|
+
|
|
71
|
+
### Lister les projets dans le répertoire courant :
|
|
72
|
+
|
|
73
|
+
```bash
|
|
74
|
+
npx intlayer projects list
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
### Lister les projets dans un répertoire spécifique :
|
|
78
|
+
|
|
79
|
+
```bash
|
|
80
|
+
npx intlayer projects list --base-dir ./packages
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
### Lister tous les projets dans le dépôt git :
|
|
84
|
+
|
|
85
|
+
```bash
|
|
86
|
+
npx intlayer projects list --git-root
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
### Utiliser l'alias raccourci :
|
|
90
|
+
|
|
91
|
+
```bash
|
|
92
|
+
npx intlayer pl --git-root
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
### Sortie au format JSON :
|
|
96
|
+
|
|
97
|
+
```bash
|
|
98
|
+
npx intlayer projects list --json
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
## Exemple de sortie :
|
|
102
|
+
|
|
103
|
+
### Sortie formatée :
|
|
104
|
+
|
|
105
|
+
```bash
|
|
106
|
+
$ npx intlayer projects list --git-root
|
|
107
|
+
|
|
108
|
+
Found 3 Intlayer project(s):
|
|
109
|
+
|
|
110
|
+
- /Users/user/workspace/packages/app
|
|
111
|
+
- /Users/user/workspace/packages/admin
|
|
112
|
+
- /Users/user/workspace/packages/shared
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
### Sortie JSON :
|
|
116
|
+
|
|
117
|
+
```bash
|
|
118
|
+
$ npx intlayer projects list --json
|
|
119
|
+
|
|
120
|
+
["/Users/user/workspace/packages/app","/Users/user/workspace/packages/admin","/Users/user/workspace/packages/shared"]
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
## Cas d'utilisation :
|
|
124
|
+
|
|
125
|
+
- **Gestion de monorepo** : Découvrir tous les projets Intlayer dans une structure monorepo
|
|
126
|
+
- **Découverte de projets** : Trouver tous les projets utilisant Intlayer dans un workspace
|
|
127
|
+
- **CI/CD** : Vérifier les projets Intlayer dans les workflows automatisés
|
|
128
|
+
- **Documentation** : Générer une documentation listant tous les projets utilisant Intlayer
|
|
129
|
+
- **Documentation** : Générer une documentation listant tous les projets utilisant Intlayer
|
|
130
|
+
|
|
131
|
+
La sortie fournit des chemins absolus vers chaque répertoire de projet, ce qui facilite la navigation ou l'automatisation d'opérations sur plusieurs projets Intlayer.
|
package/docs/fr/intlayer_CMS.md
CHANGED
|
@@ -71,6 +71,26 @@ Pour l’intégration avec Vite + React, référez-vous au [guide d’installati
|
|
|
71
71
|
|
|
72
72
|
## Configuration
|
|
73
73
|
|
|
74
|
+
Exécutez la commande suivante pour vous connecter à l'Intlayer CMS :
|
|
75
|
+
|
|
76
|
+
```bash packageManager="npm"
|
|
77
|
+
npx intlayer login
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
```bash packageManager="yarn"
|
|
81
|
+
yarn intlayer login
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
```bash packageManager="pnpm"
|
|
85
|
+
pnpm intlayer login
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
```bash packageManager="bun"
|
|
89
|
+
bunx intlayer login
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
Cela ouvrira votre navigateur par défaut pour compléter le processus d'authentification et recevoir les identifiants nécessaires (Client ID et Client Secret) pour utiliser les services Intlayer.
|
|
93
|
+
|
|
74
94
|
Dans votre fichier de configuration Intlayer, vous pouvez personnaliser les paramètres du CMS :
|
|
75
95
|
|
|
76
96
|
```typescript fileName="intlayer.config.ts" codeFormat="typescript"
|
|
@@ -74,6 +74,34 @@ bunx intlayer init
|
|
|
74
74
|
|
|
75
75
|
### Étape 2 : Configurer votre projet
|
|
76
76
|
|
|
77
|
+
Here is the final structure that we will make:
|
|
78
|
+
|
|
79
|
+
```bash
|
|
80
|
+
.
|
|
81
|
+
├── src
|
|
82
|
+
│ ├── app
|
|
83
|
+
│ │ ├── [locale]
|
|
84
|
+
│ │ │ ├── layout.tsx # Locale layout for the Intlayer provider
|
|
85
|
+
│ │ │ ├── page.content.ts
|
|
86
|
+
│ │ │ └── page.tsx
|
|
87
|
+
│ │ └── layout.tsx # Root layout for style and global providers
|
|
88
|
+
│ ├── components
|
|
89
|
+
│ │ ├── client-component-example.content.ts
|
|
90
|
+
│ │ ├── ClientComponentExample.tsx
|
|
91
|
+
│ │ ├── LocaleSwitcher
|
|
92
|
+
│ │ │ ├── localeSwitcher.content.ts
|
|
93
|
+
│ │ │ └── LocaleSwitcher.tsx
|
|
94
|
+
│ │ ├── server-component-example.content.ts
|
|
95
|
+
│ │ └── ServerComponentExample.tsx
|
|
96
|
+
│ └── middleware.ts
|
|
97
|
+
├── intlayer.config.ts
|
|
98
|
+
├── next.config.ts
|
|
99
|
+
├── package.json
|
|
100
|
+
└── tsconfig.json
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
> If you don't want locale routing, intlayer can be used as a simple provider / hook. See [this guide](https://github.com/aymericzip/intlayer/blob/main/docs/docs/en/intlayer_with_nextjs_no_locale_path.md) for more details.
|
|
104
|
+
|
|
77
105
|
Créez un fichier de configuration pour configurer les langues de votre application :
|
|
78
106
|
|
|
79
107
|
```typescript fileName="intlayer.config.ts" codeFormat="typescript"
|
|
@@ -84,6 +84,34 @@ bunx intlayer init
|
|
|
84
84
|
|
|
85
85
|
### Étape 2 : Configurez votre projet
|
|
86
86
|
|
|
87
|
+
Here is the final structure that we will make:
|
|
88
|
+
|
|
89
|
+
```bash
|
|
90
|
+
.
|
|
91
|
+
├── src
|
|
92
|
+
│ ├── app
|
|
93
|
+
│ │ ├── [locale]
|
|
94
|
+
│ │ │ ├── layout.tsx # Locale layout for the Intlayer provider
|
|
95
|
+
│ │ │ ├── page.content.ts
|
|
96
|
+
│ │ │ └── page.tsx
|
|
97
|
+
│ │ └── layout.tsx # Root layout for style and global providers
|
|
98
|
+
│ ├── components
|
|
99
|
+
│ │ ├── client-component-example.content.ts
|
|
100
|
+
│ │ ├── ClientComponentExample.tsx
|
|
101
|
+
│ │ ├── LocaleSwitcher
|
|
102
|
+
│ │ │ ├── localeSwitcher.content.ts
|
|
103
|
+
│ │ │ └── LocaleSwitcher.tsx
|
|
104
|
+
│ │ ├── server-component-example.content.ts
|
|
105
|
+
│ │ └── ServerComponentExample.tsx
|
|
106
|
+
│ └── middleware.ts
|
|
107
|
+
├── intlayer.config.ts
|
|
108
|
+
├── next.config.ts
|
|
109
|
+
├── package.json
|
|
110
|
+
└── tsconfig.json
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
> If you don't want locale routing, intlayer can be used as a simple provider / hook. See [this guide](https://github.com/aymericzip/intlayer/blob/main/docs/docs/en/intlayer_with_nextjs_no_locale_path.md) for more details.
|
|
114
|
+
|
|
87
115
|
Créez un fichier de configuration pour configurer les langues de votre application :
|
|
88
116
|
|
|
89
117
|
```typescript fileName="intlayer.config.ts" codeFormat="typescript"
|
|
@@ -104,6 +104,34 @@ Le package qui intègre Intlayer avec Next.js. Il fournit des fournisseurs de co
|
|
|
104
104
|
|
|
105
105
|
### Étape 2 : Configurez votre projet
|
|
106
106
|
|
|
107
|
+
Here is the final structure that we will make:
|
|
108
|
+
|
|
109
|
+
```bash
|
|
110
|
+
.
|
|
111
|
+
├── src
|
|
112
|
+
│ ├── app
|
|
113
|
+
│ │ ├── [locale]
|
|
114
|
+
│ │ │ ├── layout.tsx # Locale layout for the Intlayer provider
|
|
115
|
+
│ │ │ ├── page.content.ts
|
|
116
|
+
│ │ │ └── page.tsx
|
|
117
|
+
│ │ └── layout.tsx # Root layout for style and global providers
|
|
118
|
+
│ ├── components
|
|
119
|
+
│ │ ├── client-component-example.content.ts
|
|
120
|
+
│ │ ├── ClientComponentExample.tsx
|
|
121
|
+
│ │ ├── LocaleSwitcher
|
|
122
|
+
│ │ │ ├── localeSwitcher.content.ts
|
|
123
|
+
│ │ │ └── LocaleSwitcher.tsx
|
|
124
|
+
│ │ ├── server-component-example.content.ts
|
|
125
|
+
│ │ └── ServerComponentExample.tsx
|
|
126
|
+
│ └── proxy.ts
|
|
127
|
+
├── intlayer.config.ts
|
|
128
|
+
├── next.config.ts
|
|
129
|
+
├── package.json
|
|
130
|
+
└── tsconfig.json
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
> If you don't want locale routing, intlayer can be used as a simple provider / hook. See [this guide](https://github.com/aymericzip/intlayer/blob/main/docs/docs/en/intlayer_with_nextjs_no_locale_path.md) for more details.
|
|
134
|
+
|
|
107
135
|
Créez un fichier de configuration pour configurer les langues de votre application :
|
|
108
136
|
|
|
109
137
|
```typescript fileName="intlayer.config.ts" codeFormat="typescript"
|