@intlayer/docs 5.8.1-canary.0 → 6.0.0-canary.0
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/rag_powered_documentation_assistant.md +282 -0
- package/blog/de/rag_powered_documentation_assistant.md +282 -0
- package/blog/en/rag_powered_documentation_assistant.md +289 -0
- package/blog/en-GB/rag_powered_documentation_assistant.md +284 -0
- package/blog/es/rag_powered_documentation_assistant.md +308 -0
- package/blog/fr/rag_powered_documentation_assistant.md +308 -0
- package/blog/hi/rag_powered_documentation_assistant.md +284 -0
- package/blog/it/rag_powered_documentation_assistant.md +284 -0
- package/blog/ja/rag_powered_documentation_assistant.md +284 -0
- package/blog/ko/rag_powered_documentation_assistant.md +283 -0
- package/blog/pt/rag_powered_documentation_assistant.md +284 -0
- package/blog/ru/rag_powered_documentation_assistant.md +284 -0
- package/blog/tr/index.md +69 -0
- package/blog/tr/internationalization_and_SEO.md +273 -0
- package/blog/tr/intlayer_with_i18next.md +162 -0
- package/blog/tr/intlayer_with_next-i18next.md +367 -0
- package/blog/tr/intlayer_with_next-intl.md +392 -0
- package/blog/tr/intlayer_with_react-i18next.md +346 -0
- package/blog/tr/intlayer_with_react-intl.md +345 -0
- package/blog/tr/list_i18n_technologies/CMS/drupal.md +143 -0
- package/blog/tr/list_i18n_technologies/CMS/wix.md +167 -0
- package/blog/tr/list_i18n_technologies/CMS/wordpress.md +188 -0
- package/blog/tr/list_i18n_technologies/frameworks/angular.md +125 -0
- package/blog/tr/list_i18n_technologies/frameworks/flutter.md +150 -0
- package/blog/tr/list_i18n_technologies/frameworks/react-native.md +217 -0
- package/blog/tr/list_i18n_technologies/frameworks/react.md +155 -0
- package/blog/tr/list_i18n_technologies/frameworks/svelte.md +129 -0
- package/blog/tr/list_i18n_technologies/frameworks/vue.md +130 -0
- package/blog/tr/next-i18next_vs_next-intl_vs_intlayer.md +170 -0
- package/blog/tr/rag_powered_documentation_assistant.md +284 -0
- package/blog/tr/react-i18next_vs_react-intl_vs_intlayer.md +162 -0
- package/blog/tr/vue-i18n_vs_intlayer.md +276 -0
- package/blog/tr/what_is_internationalization.md +166 -0
- package/blog/zh/rag_powered_documentation_assistant.md +284 -0
- package/dist/cjs/generated/blog.entry.cjs +212 -0
- package/dist/cjs/generated/blog.entry.cjs.map +1 -1
- package/dist/cjs/generated/docs.entry.cjs +660 -132
- package/dist/cjs/generated/docs.entry.cjs.map +1 -1
- package/dist/cjs/generated/frequentQuestions.entry.cjs +84 -0
- package/dist/cjs/generated/frequentQuestions.entry.cjs.map +1 -1
- package/dist/cjs/generated/legal.entry.cjs +6 -0
- package/dist/cjs/generated/legal.entry.cjs.map +1 -1
- package/dist/esm/generated/blog.entry.mjs +212 -0
- package/dist/esm/generated/blog.entry.mjs.map +1 -1
- package/dist/esm/generated/docs.entry.mjs +660 -132
- package/dist/esm/generated/docs.entry.mjs.map +1 -1
- package/dist/esm/generated/frequentQuestions.entry.mjs +84 -0
- package/dist/esm/generated/frequentQuestions.entry.mjs.map +1 -1
- package/dist/esm/generated/legal.entry.mjs +6 -0
- package/dist/esm/generated/legal.entry.mjs.map +1 -1
- package/dist/types/generated/blog.entry.d.ts +1 -0
- package/dist/types/generated/blog.entry.d.ts.map +1 -1
- package/dist/types/generated/docs.entry.d.ts +5 -2
- 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/autoFill.md +41 -40
- package/docs/ar/configuration.md +202 -199
- package/docs/ar/dictionary/content_file.md +1059 -0
- package/docs/ar/intlayer_CMS.md +4 -4
- package/docs/ar/intlayer_with_nestjs.md +271 -0
- package/docs/ar/intlayer_with_nextjs_page_router.md +1 -1
- package/docs/ar/intlayer_with_react_router_v7.md +533 -0
- package/docs/ar/intlayer_with_tanstack.md +465 -299
- package/docs/ar/intlayer_with_vite+preact.md +7 -7
- package/docs/ar/intlayer_with_vite+react.md +7 -7
- package/docs/ar/intlayer_with_vite+vue.md +9 -9
- package/docs/ar/packages/vite-intlayer/index.md +3 -3
- package/docs/ar/readme.md +261 -0
- package/docs/ar/testing.md +199 -0
- package/docs/de/autoFill.md +42 -19
- package/docs/de/configuration.md +155 -147
- package/docs/de/dictionary/content_file.md +1059 -0
- package/docs/de/intlayer_CMS.md +4 -5
- package/docs/de/intlayer_with_nestjs.md +270 -0
- package/docs/de/intlayer_with_nextjs_page_router.md +1 -1
- package/docs/de/intlayer_with_react_router_v7.md +537 -0
- package/docs/de/intlayer_with_tanstack.md +469 -302
- package/docs/de/intlayer_with_vite+preact.md +7 -7
- package/docs/de/intlayer_with_vite+react.md +7 -7
- package/docs/de/intlayer_with_vite+vue.md +9 -9
- package/docs/de/packages/vite-intlayer/index.md +3 -3
- package/docs/de/readme.md +261 -0
- package/docs/de/testing.md +200 -0
- package/docs/en/CI_CD.md +4 -6
- package/docs/en/autoFill.md +25 -5
- package/docs/en/configuration.md +45 -54
- package/docs/en/dictionary/content_file.md +1054 -0
- package/docs/en/intlayer_CMS.md +8 -7
- package/docs/en/intlayer_cli.md +112 -5
- package/docs/en/intlayer_with_nestjs.md +268 -0
- package/docs/en/intlayer_with_nextjs_page_router.md +1 -1
- package/docs/en/intlayer_with_react_router_v7.md +531 -0
- package/docs/en/intlayer_with_tanstack.md +463 -294
- package/docs/en/intlayer_with_vite+preact.md +8 -8
- package/docs/en/intlayer_with_vite+react.md +8 -8
- package/docs/en/intlayer_with_vite+vue.md +8 -8
- package/docs/en/packages/intlayer/getLocalizedUrl.md +102 -25
- package/docs/en/packages/vite-intlayer/index.md +3 -3
- package/docs/en/readme.md +261 -0
- package/docs/en/testing.md +200 -0
- package/docs/en-GB/autoFill.md +29 -6
- package/docs/en-GB/configuration.md +79 -71
- package/docs/en-GB/dictionary/content_file.md +1084 -0
- package/docs/en-GB/intlayer_CMS.md +4 -5
- package/docs/en-GB/intlayer_with_nestjs.md +268 -0
- package/docs/en-GB/intlayer_with_nextjs_page_router.md +1 -1
- package/docs/en-GB/intlayer_with_react_router_v7.md +533 -0
- package/docs/en-GB/intlayer_with_tanstack.md +466 -299
- package/docs/en-GB/intlayer_with_vite+preact.md +7 -7
- package/docs/en-GB/intlayer_with_vite+react.md +7 -7
- package/docs/en-GB/intlayer_with_vite+vue.md +9 -9
- package/docs/en-GB/packages/vite-intlayer/index.md +3 -3
- package/docs/en-GB/readme.md +261 -0
- package/docs/en-GB/testing.md +200 -0
- package/docs/es/autoFill.md +45 -23
- package/docs/es/configuration.md +171 -167
- package/docs/es/dictionary/content_file.md +1088 -0
- package/docs/es/intlayer_CMS.md +4 -5
- package/docs/es/intlayer_with_nestjs.md +268 -0
- package/docs/es/intlayer_with_nextjs_page_router.md +1 -1
- package/docs/es/intlayer_with_react_router_v7.md +533 -0
- package/docs/es/intlayer_with_tanstack.md +469 -280
- package/docs/es/intlayer_with_vite+preact.md +7 -7
- package/docs/es/intlayer_with_vite+react.md +7 -7
- package/docs/es/intlayer_with_vite+vue.md +9 -9
- package/docs/es/packages/vite-intlayer/index.md +3 -3
- package/docs/es/readme.md +261 -0
- package/docs/es/testing.md +200 -0
- package/docs/fr/autoFill.md +47 -24
- package/docs/fr/configuration.md +213 -198
- package/docs/fr/dictionary/content_file.md +1054 -0
- package/docs/fr/intlayer_CMS.md +4 -5
- package/docs/fr/intlayer_with_nestjs.md +268 -0
- package/docs/fr/intlayer_with_nextjs_page_router.md +1 -1
- package/docs/fr/intlayer_with_react_router_v7.md +549 -0
- package/docs/fr/intlayer_with_tanstack.md +465 -279
- package/docs/fr/intlayer_with_vite+preact.md +7 -7
- package/docs/fr/intlayer_with_vite+react.md +7 -7
- package/docs/fr/intlayer_with_vite+vue.md +9 -9
- package/docs/fr/packages/vite-intlayer/index.md +3 -3
- package/docs/fr/readme.md +261 -0
- package/docs/fr/testing.md +200 -0
- package/docs/hi/autoFill.md +47 -25
- package/docs/hi/configuration.md +194 -189
- package/docs/hi/dictionary/content_file.md +1056 -0
- package/docs/hi/intlayer_CMS.md +4 -5
- package/docs/hi/intlayer_with_nestjs.md +269 -0
- package/docs/hi/intlayer_with_nextjs_page_router.md +1 -1
- package/docs/hi/intlayer_with_react_router_v7.md +533 -0
- package/docs/hi/intlayer_with_tanstack.md +467 -282
- package/docs/hi/intlayer_with_vite+preact.md +7 -7
- package/docs/hi/intlayer_with_vite+react.md +7 -7
- package/docs/hi/intlayer_with_vite+vue.md +9 -9
- package/docs/hi/packages/vite-intlayer/index.md +3 -3
- package/docs/hi/readme.md +261 -0
- package/docs/hi/testing.md +200 -0
- package/docs/it/autoFill.md +46 -24
- package/docs/it/configuration.md +169 -161
- package/docs/it/dictionary/content_file.md +1061 -0
- package/docs/it/intlayer_CMS.md +4 -5
- package/docs/it/intlayer_with_nestjs.md +268 -0
- package/docs/it/intlayer_with_nextjs_page_router.md +1 -1
- package/docs/it/intlayer_with_react_router_v7.md +535 -0
- package/docs/it/intlayer_with_tanstack.md +467 -301
- package/docs/it/intlayer_with_vite+preact.md +7 -7
- package/docs/it/intlayer_with_vite+react.md +7 -7
- package/docs/it/intlayer_with_vite+vue.md +9 -9
- package/docs/it/packages/vite-intlayer/index.md +3 -3
- package/docs/it/readme.md +261 -0
- package/docs/it/testing.md +200 -0
- package/docs/ja/autoFill.md +45 -23
- package/docs/ja/configuration.md +243 -204
- package/docs/ja/dictionary/content_file.md +1064 -0
- package/docs/ja/intlayer_CMS.md +4 -5
- package/docs/ja/intlayer_with_nestjs.md +268 -0
- package/docs/ja/intlayer_with_nextjs_page_router.md +1 -1
- package/docs/ja/intlayer_with_react_router_v7.md +534 -0
- package/docs/ja/intlayer_with_tanstack.md +467 -303
- package/docs/ja/intlayer_with_vite+preact.md +7 -7
- package/docs/ja/intlayer_with_vite+react.md +7 -7
- package/docs/ja/intlayer_with_vite+vue.md +9 -9
- package/docs/ja/packages/vite-intlayer/index.md +3 -3
- package/docs/ja/readme.md +263 -0
- package/docs/ja/testing.md +200 -0
- package/docs/ko/autoFill.md +39 -16
- package/docs/ko/configuration.md +217 -197
- package/docs/ko/dictionary/content_file.md +1060 -0
- package/docs/ko/intlayer_CMS.md +4 -5
- package/docs/ko/intlayer_with_nestjs.md +268 -0
- package/docs/ko/intlayer_with_nextjs_page_router.md +1 -1
- package/docs/ko/intlayer_with_react_router_v7.md +540 -0
- package/docs/ko/intlayer_with_tanstack.md +466 -302
- package/docs/ko/intlayer_with_vite+preact.md +7 -7
- package/docs/ko/intlayer_with_vite+react.md +7 -7
- package/docs/ko/intlayer_with_vite+vue.md +9 -9
- package/docs/ko/packages/vite-intlayer/index.md +3 -3
- package/docs/ko/readme.md +261 -0
- package/docs/ko/testing.md +200 -0
- package/docs/pt/autoFill.md +39 -15
- package/docs/pt/configuration.md +165 -147
- package/docs/pt/dictionary/content_file.md +1062 -0
- package/docs/pt/intlayer_CMS.md +4 -5
- package/docs/pt/intlayer_with_nestjs.md +271 -0
- package/docs/pt/intlayer_with_nextjs_page_router.md +1 -1
- package/docs/pt/intlayer_with_react_router_v7.md +535 -0
- package/docs/pt/intlayer_with_tanstack.md +469 -300
- package/docs/pt/intlayer_with_vite+preact.md +7 -7
- package/docs/pt/intlayer_with_vite+react.md +7 -7
- package/docs/pt/intlayer_with_vite+vue.md +9 -9
- package/docs/pt/packages/vite-intlayer/index.md +3 -3
- package/docs/pt/readme.md +261 -0
- package/docs/pt/testing.md +200 -0
- package/docs/ru/autoFill.md +52 -30
- package/docs/ru/configuration.md +164 -117
- package/docs/ru/dictionary/content_file.md +1064 -0
- package/docs/ru/intlayer_CMS.md +4 -4
- package/docs/ru/intlayer_with_nestjs.md +270 -0
- package/docs/ru/intlayer_with_nextjs_page_router.md +1 -1
- package/docs/ru/intlayer_with_react_router_v7.md +534 -0
- package/docs/ru/intlayer_with_tanstack.md +470 -305
- package/docs/ru/intlayer_with_vite+preact.md +7 -7
- package/docs/ru/intlayer_with_vite+react.md +7 -7
- package/docs/ru/intlayer_with_vite+vue.md +9 -9
- package/docs/ru/packages/vite-intlayer/index.md +3 -3
- package/docs/ru/readme.md +261 -0
- package/docs/ru/testing.md +202 -0
- package/docs/tr/CI_CD.md +198 -0
- package/docs/tr/autoFill.md +201 -0
- package/docs/tr/configuration.md +585 -0
- package/docs/tr/dictionary/condition.md +243 -0
- package/docs/tr/dictionary/content_file.md +1055 -0
- package/docs/tr/dictionary/enumeration.md +251 -0
- package/docs/tr/dictionary/file.md +228 -0
- package/docs/tr/dictionary/function_fetching.md +218 -0
- package/docs/tr/dictionary/gender.md +279 -0
- package/docs/tr/dictionary/insertion.md +191 -0
- package/docs/tr/dictionary/markdown.md +385 -0
- package/docs/tr/dictionary/nesting.md +279 -0
- package/docs/tr/dictionary/translation.md +315 -0
- package/docs/tr/formatters.md +618 -0
- package/docs/tr/how_works_intlayer.md +254 -0
- package/docs/tr/index.md +168 -0
- package/docs/tr/interest_of_intlayer.md +288 -0
- package/docs/tr/intlayer_CMS.md +347 -0
- package/docs/tr/intlayer_cli.md +570 -0
- package/docs/tr/intlayer_visual_editor.md +269 -0
- package/docs/tr/intlayer_with_angular.md +694 -0
- package/docs/tr/intlayer_with_create_react_app.md +1218 -0
- package/docs/tr/intlayer_with_express.md +415 -0
- package/docs/tr/intlayer_with_lynx+react.md +511 -0
- package/docs/tr/intlayer_with_nestjs.md +268 -0
- package/docs/tr/intlayer_with_nextjs_14.md +1029 -0
- package/docs/tr/intlayer_with_nextjs_15.md +1506 -0
- package/docs/tr/intlayer_with_nextjs_page_router.md +1484 -0
- package/docs/tr/intlayer_with_nuxt.md +773 -0
- package/docs/tr/intlayer_with_react_native+expo.md +660 -0
- package/docs/tr/intlayer_with_react_router_v7.md +531 -0
- package/docs/tr/intlayer_with_tanstack.md +452 -0
- package/docs/tr/intlayer_with_vite+preact.md +1673 -0
- package/docs/tr/intlayer_with_vite+react.md +1632 -0
- package/docs/tr/intlayer_with_vite+solid.md +288 -0
- package/docs/tr/intlayer_with_vite+svelte.md +288 -0
- package/docs/tr/intlayer_with_vite+vue.md +1042 -0
- package/docs/tr/introduction.md +209 -0
- package/docs/tr/locale_mapper.md +244 -0
- package/docs/tr/mcp_server.md +207 -0
- package/docs/tr/packages/@intlayer/api/index.md +58 -0
- package/docs/tr/packages/@intlayer/chokidar/index.md +57 -0
- package/docs/tr/packages/@intlayer/cli/index.md +47 -0
- package/docs/tr/packages/@intlayer/config/index.md +142 -0
- package/docs/tr/packages/@intlayer/core/index.md +51 -0
- package/docs/tr/packages/@intlayer/design-system/index.md +47 -0
- package/docs/tr/packages/@intlayer/dictionary-entry/index.md +53 -0
- package/docs/tr/packages/@intlayer/editor/index.md +47 -0
- package/docs/tr/packages/@intlayer/editor-react/index.md +47 -0
- package/docs/tr/packages/@intlayer/webpack/index.md +61 -0
- package/docs/tr/packages/angular-intlayer/index.md +59 -0
- package/docs/tr/packages/express-intlayer/index.md +258 -0
- package/docs/tr/packages/express-intlayer/t.md +459 -0
- package/docs/tr/packages/intlayer/getConfiguration.md +151 -0
- package/docs/tr/packages/intlayer/getEnumeration.md +165 -0
- package/docs/tr/packages/intlayer/getHTMLTextDir.md +127 -0
- package/docs/tr/packages/intlayer/getLocaleLang.md +87 -0
- package/docs/tr/packages/intlayer/getLocaleName.md +124 -0
- package/docs/tr/packages/intlayer/getLocalizedUrl.md +324 -0
- package/docs/tr/packages/intlayer/getMultilingualUrls.md +225 -0
- package/docs/tr/packages/intlayer/getPathWithoutLocale.md +81 -0
- package/docs/tr/packages/intlayer/getTranslation.md +196 -0
- package/docs/tr/packages/intlayer/getTranslationContent.md +195 -0
- package/docs/tr/packages/intlayer/index.md +505 -0
- package/docs/tr/packages/intlayer-cli/index.md +71 -0
- package/docs/tr/packages/intlayer-editor/index.md +139 -0
- package/docs/tr/packages/lynx-intlayer/index.md +85 -0
- package/docs/tr/packages/next-intlayer/index.md +154 -0
- package/docs/tr/packages/next-intlayer/t.md +354 -0
- package/docs/tr/packages/next-intlayer/useDictionary.md +270 -0
- package/docs/tr/packages/next-intlayer/useIntlayer.md +265 -0
- package/docs/tr/packages/next-intlayer/useLocale.md +133 -0
- package/docs/tr/packages/nuxt-intlayer/index.md +59 -0
- package/docs/tr/packages/preact-intlayer/index.md +55 -0
- package/docs/tr/packages/react-intlayer/index.md +148 -0
- package/docs/tr/packages/react-intlayer/t.md +304 -0
- package/docs/tr/packages/react-intlayer/useDictionary.md +554 -0
- package/docs/tr/packages/react-intlayer/useI18n.md +478 -0
- package/docs/tr/packages/react-intlayer/useIntlayer.md +253 -0
- package/docs/tr/packages/react-intlayer/useLocale.md +212 -0
- package/docs/tr/packages/react-native-intlayer/index.md +85 -0
- package/docs/tr/packages/react-scripts-intlayer/index.md +82 -0
- package/docs/tr/packages/solid-intlayer/index.md +56 -0
- package/docs/tr/packages/svelte-intlayer/index.md +55 -0
- package/docs/tr/packages/vite-intlayer/index.md +82 -0
- package/docs/tr/packages/vue-intlayer/index.md +59 -0
- package/docs/tr/per_locale_file.md +321 -0
- package/docs/tr/readme.md +261 -0
- package/docs/tr/roadmap.md +338 -0
- package/docs/tr/testing.md +200 -0
- package/docs/tr/vs_code_extension.md +154 -0
- package/docs/zh/autoFill.md +40 -18
- package/docs/zh/configuration.md +245 -226
- package/docs/zh/dictionary/content_file.md +1064 -0
- package/docs/zh/intlayer_CMS.md +4 -5
- package/docs/zh/intlayer_with_nestjs.md +268 -0
- package/docs/zh/intlayer_with_nextjs_page_router.md +1 -1
- package/docs/zh/intlayer_with_react_router_v7.md +535 -0
- package/docs/zh/intlayer_with_tanstack.md +468 -278
- package/docs/zh/intlayer_with_vite+preact.md +7 -7
- package/docs/zh/intlayer_with_vite+react.md +7 -7
- package/docs/zh/intlayer_with_vite+vue.md +7 -7
- package/docs/zh/packages/vite-intlayer/index.md +3 -3
- package/docs/zh/readme.md +261 -0
- package/docs/zh/testing.md +198 -0
- package/frequent_questions/tr/SSR_Next_no_[locale].md +105 -0
- package/frequent_questions/tr/array_as_content_declaration.md +72 -0
- package/frequent_questions/tr/build_dictionaries.md +59 -0
- package/frequent_questions/tr/build_error_CI_CD.md +75 -0
- package/frequent_questions/tr/customized_locale_list.md +65 -0
- package/frequent_questions/tr/domain_routing.md +114 -0
- package/frequent_questions/tr/esbuild_error.md +30 -0
- package/frequent_questions/tr/get_locale_cookie.md +142 -0
- package/frequent_questions/tr/intlayer_command_undefined.md +156 -0
- package/frequent_questions/tr/locale_incorect_in_url.md +74 -0
- package/frequent_questions/tr/static_rendering.md +45 -0
- package/frequent_questions/tr/translated_path_url.md +56 -0
- package/frequent_questions/tr/unknown_command.md +98 -0
- package/legal/tr/privacy_notice.md +83 -0
- package/legal/tr/terms_of_service.md +55 -0
- package/package.json +13 -13
- package/src/generated/blog.entry.ts +212 -0
- package/src/generated/docs.entry.ts +663 -135
- package/src/generated/frequentQuestions.entry.ts +85 -1
- package/src/generated/legal.entry.ts +7 -1
- package/docs/ar/dictionary/content_extention_customization.md +0 -100
- package/docs/ar/dictionary/get_started.md +0 -527
- package/docs/de/dictionary/content_extention_customization.md +0 -100
- package/docs/de/dictionary/get_started.md +0 -531
- package/docs/en/dictionary/content_extention_customization.md +0 -102
- package/docs/en/dictionary/get_started.md +0 -529
- package/docs/en-GB/dictionary/content_extention_customization.md +0 -100
- package/docs/en-GB/dictionary/get_started.md +0 -591
- package/docs/es/dictionary/content_extention_customization.md +0 -100
- package/docs/es/dictionary/get_started.md +0 -527
- package/docs/fr/dictionary/content_extention_customization.md +0 -100
- package/docs/fr/dictionary/get_started.md +0 -527
- package/docs/hi/dictionary/content_extention_customization.md +0 -100
- package/docs/hi/dictionary/get_started.md +0 -527
- package/docs/it/dictionary/content_extention_customization.md +0 -113
- package/docs/it/dictionary/get_started.md +0 -573
- package/docs/ja/dictionary/content_extention_customization.md +0 -113
- package/docs/ja/dictionary/get_started.md +0 -576
- package/docs/ko/dictionary/content_extention_customization.md +0 -100
- package/docs/ko/dictionary/get_started.md +0 -530
- package/docs/pt/dictionary/content_extention_customization.md +0 -100
- package/docs/pt/dictionary/get_started.md +0 -532
- package/docs/ru/dictionary/content_extention_customization.md +0 -100
- package/docs/ru/dictionary/get_started.md +0 -575
- package/docs/zh/dictionary/content_extention_customization.md +0 -117
- package/docs/zh/dictionary/get_started.md +0 -533
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
createdAt: 2024-08-13
|
|
3
|
-
updatedAt: 2025-
|
|
3
|
+
updatedAt: 2025-09-16
|
|
4
4
|
title: Configuration
|
|
5
5
|
description: Learn how to configure Intlayer for your application. Understand the various settings and options available to customise Intlayer to your needs.
|
|
6
6
|
keywords:
|
|
@@ -46,6 +46,7 @@ const config: IntlayerConfig = {
|
|
|
46
46
|
locales: [Locales.ENGLISH],
|
|
47
47
|
},
|
|
48
48
|
content: {
|
|
49
|
+
autoFill: "./{{fileName}}.content.json",
|
|
49
50
|
contentDir: ["src", "../ui-library"],
|
|
50
51
|
},
|
|
51
52
|
middleware: {
|
|
@@ -70,6 +71,7 @@ export default config;
|
|
|
70
71
|
const { Locales } = require("intlayer");
|
|
71
72
|
|
|
72
73
|
/** @type {import('intlayer').IntlayerConfig} */
|
|
74
|
+
// Configuration object for Intlayer
|
|
73
75
|
const config = {
|
|
74
76
|
internationalization: {
|
|
75
77
|
locales: [Locales.ENGLISH],
|
|
@@ -101,11 +103,21 @@ module.exports = config;
|
|
|
101
103
|
"locales": ["en"],
|
|
102
104
|
},
|
|
103
105
|
"content": {
|
|
104
|
-
"
|
|
106
|
+
"contentDir": ["src", "../ui-library"],
|
|
105
107
|
},
|
|
106
108
|
"middleware": {
|
|
107
109
|
"noPrefix": false,
|
|
108
110
|
},
|
|
111
|
+
"editor": {
|
|
112
|
+
"applicationURL": "https://example.com",
|
|
113
|
+
},
|
|
114
|
+
"ai": {
|
|
115
|
+
"apiKey": "XXXX",
|
|
116
|
+
"applicationContext": "This is a test application",
|
|
117
|
+
},
|
|
118
|
+
"build": {
|
|
119
|
+
"importMode": "dynamic",
|
|
120
|
+
},
|
|
109
121
|
}
|
|
110
122
|
```
|
|
111
123
|
|
|
@@ -124,7 +136,6 @@ Defines settings related to internationalisation, including available locales an
|
|
|
124
136
|
#### Properties
|
|
125
137
|
|
|
126
138
|
- **locales**:
|
|
127
|
-
|
|
128
139
|
- _Type_: `string[]`
|
|
129
140
|
- _Default_: `['en']`
|
|
130
141
|
- _Description_: The list of supported locales in the application.
|
|
@@ -138,16 +149,14 @@ Defines settings related to internationalisation, including available locales an
|
|
|
138
149
|
- _Note_: If empty, all locales are required in `strict` mode.
|
|
139
150
|
- _Note_: Ensure required locales are also defined in the `locales` field.
|
|
140
151
|
- **strictMode**:
|
|
141
|
-
|
|
142
152
|
- _Type_: `string`
|
|
143
153
|
- _Default_: `inclusive`
|
|
144
|
-
- _Description_:
|
|
154
|
+
- _Description_: Ensures strong implementations of internationalised content using TypeScript.
|
|
145
155
|
- _Note_: If set to "strict", the translation `t` function will require each declared locale to be defined. If one locale is missing, or if a locale is not declared in your config, it will throw an error.
|
|
146
|
-
- _Note_: If set to "inclusive", the translation `t` function will require each declared locale to be defined. If one locale is missing, it will throw a warning. But will accept if a locale is not declared in your config, but exists.
|
|
156
|
+
- _Note_: If set to "inclusive", the translation `t` function will require each declared locale to be defined. If one locale is missing, it will throw a warning. But it will accept if a locale is not declared in your config, but exists.
|
|
147
157
|
- _Note_: If set to "loose", the translation `t` function will accept any existing locale.
|
|
148
158
|
|
|
149
159
|
- **defaultLocale**:
|
|
150
|
-
|
|
151
160
|
- _Type_: `string`
|
|
152
161
|
- _Default_: `'en'`
|
|
153
162
|
- _Description_: The default locale used as a fallback if the requested locale is not found.
|
|
@@ -163,7 +172,6 @@ Defines settings related to the integrated editor, including server port and act
|
|
|
163
172
|
#### Properties
|
|
164
173
|
|
|
165
174
|
- **applicationURL**:
|
|
166
|
-
|
|
167
175
|
- _Type_: `string`
|
|
168
176
|
- _Default_: `http://localhost:3000`
|
|
169
177
|
- _Description_: The URL of the application. Used to restrict the origin of the editor for security reasons.
|
|
@@ -174,23 +182,20 @@ Defines settings related to the integrated editor, including server port and act
|
|
|
174
182
|
- _Note_: The URL of the application. Used to restrict the origin of the editor for security reasons. If set to `'*'`, the editor is accessible from any origin.
|
|
175
183
|
|
|
176
184
|
- **port**:
|
|
177
|
-
|
|
178
185
|
- _Type_: `number`
|
|
179
186
|
- _Default_: `8000`
|
|
180
187
|
- _Description_: The port used by the visual editor server.
|
|
181
188
|
|
|
182
189
|
- **editorURL**:
|
|
183
|
-
|
|
184
190
|
- _Type_: `string`
|
|
185
191
|
- _Default_: `'http://localhost:8000'`
|
|
186
192
|
- _Description_: The URL of the editor server. Used to restrict the origin of the editor for security reasons.
|
|
187
193
|
- `'http://localhost:3000'`
|
|
188
194
|
- `'https://example.com'`
|
|
189
195
|
- `process.env.INTLAYER_EDITOR_URL`
|
|
190
|
-
- _Note_: The URL of the editor server to reach from the application. Used to restrict the origins that can interact with the application for security reasons. If set to `'*'`, the editor is accessible from any origin. Should be set if port is changed, or if the editor is hosted on a different domain.
|
|
196
|
+
- _Note_: The URL of the editor server to reach from the application. Used to restrict the origins that can interact with the application for security reasons. If set to `'*'`, the editor is accessible from any origin. Should be set if the port is changed, or if the editor is hosted on a different domain.
|
|
191
197
|
|
|
192
198
|
- **cmsURL**:
|
|
193
|
-
|
|
194
199
|
- _Type_: `string`
|
|
195
200
|
- _Default_: `'https://intlayer.org'`
|
|
196
201
|
- _Description_: The URL of the Intlayer CMS.
|
|
@@ -198,14 +203,12 @@ Defines settings related to the integrated editor, including server port and act
|
|
|
198
203
|
- _Note_: The URL of the Intlayer CMS.
|
|
199
204
|
|
|
200
205
|
- **backendURL**:
|
|
201
|
-
|
|
202
206
|
- _Type_: `string`
|
|
203
207
|
- _Default_: `https://back.intlayer.org`
|
|
204
208
|
- _Description_: The URL of the backend server.
|
|
205
209
|
- _Example_: `http://localhost:4000`
|
|
206
210
|
|
|
207
211
|
- **enabled**:
|
|
208
|
-
|
|
209
212
|
- _Type_: `boolean`
|
|
210
213
|
- _Default_: `true`
|
|
211
214
|
- _Description_: Indicates if the application interacts with the visual editor.
|
|
@@ -213,35 +216,46 @@ Defines settings related to the integrated editor, including server port and act
|
|
|
213
216
|
- _Note_: If true, the editor will be able to interact with the application. If false, the editor will not be able to interact with the application. In any case, the editor can only be enabled by the visual editor. Disabling the editor for specific environments is a way to enforce security.
|
|
214
217
|
|
|
215
218
|
- **clientId**:
|
|
216
|
-
|
|
217
219
|
- _Type_: `string` | `undefined`
|
|
218
220
|
- _Default_: `undefined`
|
|
219
|
-
- _Description_: clientId and clientSecret allow the intlayer packages to authenticate with the backend using oAuth2 authentication. An access token is used to authenticate the user related to the project. To
|
|
221
|
+
- _Description_: clientId and clientSecret allow the intlayer packages to authenticate with the backend using oAuth2 authentication. An access token is used to authenticate the user related to the project. To obtain an access token, visit https://intlayer.org/dashboard/project and create an account.
|
|
220
222
|
- _Example_: `true`
|
|
221
|
-
- _Note_: Important: The clientId and clientSecret should be kept
|
|
223
|
+
- _Note_: Important: The clientId and clientSecret should be kept confidential and not shared publicly. Please ensure they are stored securely, such as in environment variables.
|
|
222
224
|
|
|
223
225
|
- **clientSecret**:
|
|
224
|
-
|
|
225
226
|
- _Type_: `string` | `undefined`
|
|
226
227
|
- _Default_: `undefined`
|
|
227
|
-
- _Description_: clientId and clientSecret allow the intlayer packages to authenticate with the backend using oAuth2 authentication. An access token is used to authenticate the user related to the project. To
|
|
228
|
+
- _Description_: clientId and clientSecret allow the intlayer packages to authenticate with the backend using oAuth2 authentication. An access token is used to authenticate the user related to the project. To obtain an access token, visit https://intlayer.org/dashboard/project and create an account.
|
|
228
229
|
- _Example_: `true`
|
|
229
|
-
- _Note_: Important: The clientId and clientSecret should be kept
|
|
230
|
+
- _Note_: Important: The clientId and clientSecret should be kept confidential and not shared publicly. Please ensure they are stored securely, such as in environment variables.
|
|
230
231
|
|
|
231
|
-
- **
|
|
232
|
+
- **dictionaryPriorityStrategy**:
|
|
233
|
+
- _Type_: `string`
|
|
234
|
+
- _Default_: `'local_first'`
|
|
235
|
+
- _Description_: The strategy to prioritise dictionaries in the case of both local and distant dictionaries being present. If set to `'distant_first'`, the application will prioritise distant dictionaries over local dictionaries. If set to `'local_first'`, the application will prioritise local dictionaries over distant dictionaries.
|
|
236
|
+
- _Example_: `'distant_first'`
|
|
232
237
|
|
|
238
|
+
- **liveSync**:
|
|
233
239
|
- _Type_: `boolean`
|
|
234
240
|
- _Default_: `false`
|
|
235
|
-
- _Description_: Indicates if the application should hot reload the
|
|
241
|
+
- _Description_: Indicates if the application server should hot reload the content of the application when a change is detected on the CMS / Visual Editor / Backend.
|
|
236
242
|
- _Example_: `true`
|
|
237
243
|
- _Note_: For example, when a new dictionary is added or updated, the application will update the content to display on the page.
|
|
238
|
-
- _Note_:
|
|
244
|
+
- _Note_: Live sync needs to externalise the content of the application to another server. This means that it can slightly impact the performance of the application. To limit this, we recommend hosting the application and the live sync server on the same machine. Also, the combination of live sync and `optimize` can generate a considerable number of requests to the live sync server. Depending on your infrastructure, we recommend testing both options and their combination.
|
|
239
245
|
|
|
240
|
-
- **
|
|
246
|
+
- **liveSyncPort**:
|
|
247
|
+
- _Type_: `number`
|
|
248
|
+
- _Default_: `4000`
|
|
249
|
+
- _Description_: The port of the live sync server.
|
|
250
|
+
- _Example_: `4000`
|
|
251
|
+
- _Note_: The port of the live sync server.
|
|
252
|
+
|
|
253
|
+
- **liveSyncURL**:
|
|
241
254
|
- _Type_: `string`
|
|
242
|
-
- _Default_: `'
|
|
243
|
-
- _Description_: The
|
|
244
|
-
- _Example_: `'
|
|
255
|
+
- _Default_: `'http://localhost:{liveSyncPort}'`
|
|
256
|
+
- _Description_: The URL of the live sync server.
|
|
257
|
+
- _Example_: `'https://example.com'`
|
|
258
|
+
- _Note_: Points to localhost by default but can be changed to any URL in the case of a remote live sync server.
|
|
245
259
|
|
|
246
260
|
### Middleware Configuration
|
|
247
261
|
|
|
@@ -250,7 +264,6 @@ Settings that control middleware behaviour, including how the application handle
|
|
|
250
264
|
#### Properties
|
|
251
265
|
|
|
252
266
|
- **headerName**:
|
|
253
|
-
|
|
254
267
|
- _Type_: `string`
|
|
255
268
|
- _Default_: `'x-intlayer-locale'`
|
|
256
269
|
- _Description_: The name of the HTTP header used to determine the locale.
|
|
@@ -258,7 +271,6 @@ Settings that control middleware behaviour, including how the application handle
|
|
|
258
271
|
- _Note_: This is useful for API-based locale determination.
|
|
259
272
|
|
|
260
273
|
- **cookieName**:
|
|
261
|
-
|
|
262
274
|
- _Type_: `string`
|
|
263
275
|
- _Default_: `'intlayer-locale'`
|
|
264
276
|
- _Description_: The name of the cookie used to store the locale.
|
|
@@ -266,7 +278,6 @@ Settings that control middleware behaviour, including how the application handle
|
|
|
266
278
|
- _Note_: Used to persist the locale across sessions.
|
|
267
279
|
|
|
268
280
|
- **prefixDefault**:
|
|
269
|
-
|
|
270
281
|
- _Type_: `boolean`
|
|
271
282
|
- _Default_: `false`
|
|
272
283
|
- _Description_: Whether to include the default locale in the URL.
|
|
@@ -276,7 +287,6 @@ Settings that control middleware behaviour, including how the application handle
|
|
|
276
287
|
- If `false` and `defaultLocale = 'en'`: path = `/dashboard` or `/fr/dashboard`
|
|
277
288
|
|
|
278
289
|
- **basePath**:
|
|
279
|
-
|
|
280
290
|
- _Type_: `string`
|
|
281
291
|
- _Default_: `''`
|
|
282
292
|
- _Description_: The base path for the application URLs.
|
|
@@ -288,7 +298,6 @@ Settings that control middleware behaviour, including how the application handle
|
|
|
288
298
|
- If the base path is not set, the URL will be `https://example.com/en`
|
|
289
299
|
|
|
290
300
|
- **serverSetCookie**:
|
|
291
|
-
|
|
292
301
|
- _Type_: `string`
|
|
293
302
|
- _Default_: `'always'`
|
|
294
303
|
- _Description_: Rule for setting the locale cookie on the server.
|
|
@@ -297,7 +306,6 @@ Settings that control middleware behaviour, including how the application handle
|
|
|
297
306
|
- _Note_: Controls whether the locale cookie is set on every request or never.
|
|
298
307
|
|
|
299
308
|
- **noPrefix**:
|
|
300
|
-
|
|
301
309
|
- _Type_: `boolean`
|
|
302
310
|
- _Default_: `false`
|
|
303
311
|
- _Description_: Whether to omit the locale prefix from URLs.
|
|
@@ -310,7 +318,6 @@ Settings that control middleware behaviour, including how the application handle
|
|
|
310
318
|
- If `noPrefix = true`: URL will be `https://example.com`
|
|
311
319
|
|
|
312
320
|
- **detectLocaleOnPrefetchNoPrefix**:
|
|
313
|
-
|
|
314
321
|
- _Type_: `boolean`
|
|
315
322
|
- _Default_: `false`
|
|
316
323
|
- _Description_: Controls whether locale detection occurs during Next.js prefetch requests.
|
|
@@ -342,14 +349,24 @@ Settings related to content handling within the application, including directory
|
|
|
342
349
|
|
|
343
350
|
#### Properties
|
|
344
351
|
|
|
345
|
-
- **
|
|
352
|
+
- **autoFill**:
|
|
353
|
+
- _Type_: `boolean | string | { [key in Locales]?: string }`
|
|
354
|
+
- _Default_: `undefined`
|
|
355
|
+
- _Description_: Indicates how the content should be automatically filled using AI. Can be declared globally in the `intlayer.config.ts` file.
|
|
356
|
+
- _Example_: true
|
|
357
|
+
- _Example_: `'./{{fileName}}.content.json'`
|
|
358
|
+
- _Example_: `{ fr: './{{fileName}}.fr.content.json', es: './{{fileName}}.es.content.json' }`
|
|
359
|
+
- _Note_: The auto fill configuration. It can be:
|
|
360
|
+
- boolean: Enable auto fill for all locales
|
|
361
|
+
- string: Path to a single file or template with variables
|
|
362
|
+
- object: Per-locale file paths
|
|
346
363
|
|
|
364
|
+
- **watch**:
|
|
347
365
|
- _Type_: `boolean`
|
|
348
366
|
- _Default_: `process.env.NODE_ENV === 'development'`
|
|
349
367
|
- _Description_: Indicates if Intlayer should watch for changes in the content declaration files in the app to rebuild the related dictionaries.
|
|
350
368
|
|
|
351
369
|
- **fileExtensions**:
|
|
352
|
-
|
|
353
370
|
- _Type_: `string[]`
|
|
354
371
|
- _Default_: `['.content.ts', '.content.js', '.content.cjs', '.content.mjs', '.content.json', '.content.tsx', '.content.jsx']`
|
|
355
372
|
- _Description_: File extensions to look for when building dictionaries.
|
|
@@ -357,7 +374,6 @@ Settings related to content handling within the application, including directory
|
|
|
357
374
|
- _Note_: Customising file extensions can help avoid conflicts.
|
|
358
375
|
|
|
359
376
|
- **baseDir**:
|
|
360
|
-
|
|
361
377
|
- _Type_: `string`
|
|
362
378
|
- _Default_: `process.cwd()`
|
|
363
379
|
- _Description_: The base directory for the project.
|
|
@@ -365,48 +381,41 @@ Settings related to content handling within the application, including directory
|
|
|
365
381
|
- _Note_: This is used to resolve all Intlayer-related directories.
|
|
366
382
|
|
|
367
383
|
- **dictionaryOutput**:
|
|
368
|
-
|
|
369
384
|
- _Type_: `string[]`
|
|
370
385
|
- _Default_: `['intlayer']`
|
|
371
386
|
- _Description_: The type of dictionary output to use, e.g., `'intlayer'` or `'i18next'`.
|
|
372
387
|
|
|
373
388
|
- **contentDir**:
|
|
374
|
-
|
|
375
389
|
- _Type_: `string[]`
|
|
376
|
-
- _Default_: `['
|
|
390
|
+
- _Default_: `['.']`
|
|
377
391
|
- _Example_: `['src', '../../ui-library', require.resolve("@my-package/content")]`
|
|
378
392
|
- _Description_: The directory path where content is stored.
|
|
379
393
|
|
|
380
394
|
- **dictionariesDir**:
|
|
381
|
-
|
|
382
395
|
- _Type_: `string`
|
|
383
396
|
- _Default_: `'.intlayer/dictionaries'`
|
|
384
397
|
- _Description_: The directory path for storing intermediate or output results.
|
|
385
398
|
|
|
386
399
|
- **moduleAugmentationDir**:
|
|
387
|
-
|
|
388
400
|
- _Type_: `string`
|
|
389
401
|
- _Default_: `'.intlayer/types'`
|
|
390
402
|
- _Description_: Directory for module augmentation, allowing better IDE suggestions and type checking.
|
|
391
403
|
- _Example_: `'intlayer-types'`
|
|
392
|
-
- _Note_:
|
|
404
|
+
- _Note_: Ensure this is included in `tsconfig.json`.
|
|
393
405
|
|
|
394
406
|
- **unmergedDictionariesDir**:
|
|
395
|
-
|
|
396
407
|
- _Type_: `string`
|
|
397
408
|
- _Default_: `'.intlayer/unmerged_dictionary'`
|
|
398
409
|
- _Description_: The directory for storing unmerged dictionaries.
|
|
399
410
|
- _Example_: `'translations'`
|
|
400
411
|
|
|
401
412
|
- **dictionariesDir**:
|
|
402
|
-
|
|
403
413
|
- _Type_: `string`
|
|
404
414
|
- _Default_: `'.intlayer/dictionary'`
|
|
405
415
|
- _Description_: The directory for storing localisation dictionaries.
|
|
406
416
|
- _Example_: `'translations'`
|
|
407
417
|
|
|
408
418
|
- **i18nextResourcesDir**:
|
|
409
|
-
|
|
410
419
|
- _Type_: `string`
|
|
411
420
|
- _Default_: `'i18next_dictionary'`
|
|
412
421
|
- _Description_: The directory for storing i18n dictionaries.
|
|
@@ -414,14 +423,12 @@ Settings related to content handling within the application, including directory
|
|
|
414
423
|
- _Note_: Ensure this directory is configured for the i18next output type.
|
|
415
424
|
|
|
416
425
|
- **typesDir**:
|
|
417
|
-
|
|
418
426
|
- _Type_: `string`
|
|
419
427
|
- _Default_: `'types'`
|
|
420
428
|
- _Description_: The directory for storing dictionary types.
|
|
421
429
|
- _Example_: `'intlayer-types'`
|
|
422
430
|
|
|
423
431
|
- **mainDir**:
|
|
424
|
-
|
|
425
432
|
- _Type_: `string`
|
|
426
433
|
- _Default_: `'main'`
|
|
427
434
|
- _Description_: The directory where main application files are stored.
|
|
@@ -431,7 +438,7 @@ Settings related to content handling within the application, including directory
|
|
|
431
438
|
- _Type_: `string[]`
|
|
432
439
|
- _Default_: `['node_modules']`
|
|
433
440
|
- _Description_: Directories excluded from content search.
|
|
434
|
-
- _Note_: This setting is not yet used, but
|
|
441
|
+
- _Note_: This setting is not yet used, but planned for future implementation.
|
|
435
442
|
|
|
436
443
|
### Logger Configuration
|
|
437
444
|
|
|
@@ -440,7 +447,6 @@ Settings that control the logger, including the prefix to use.
|
|
|
440
447
|
#### Properties
|
|
441
448
|
|
|
442
449
|
- **mode**:
|
|
443
|
-
|
|
444
450
|
- _Type_: `string`
|
|
445
451
|
- _Default_: `default`
|
|
446
452
|
- _Description_: Indicates the mode of the logger.
|
|
@@ -449,7 +455,6 @@ Settings that control the logger, including the prefix to use.
|
|
|
449
455
|
- _Note_: The mode of the logger. Verbose mode will log more information, but can be used for debugging purposes. Disabled mode will disable the logger.
|
|
450
456
|
|
|
451
457
|
- **prefix**:
|
|
452
|
-
|
|
453
458
|
- _Type_: `string`
|
|
454
459
|
- _Default_: `'[intlayer] '`
|
|
455
460
|
- _Description_: The prefix of the logger.
|
|
@@ -459,10 +464,12 @@ Settings that control the logger, including the prefix to use.
|
|
|
459
464
|
### AI Configuration
|
|
460
465
|
|
|
461
466
|
Settings that control the AI features of Intlayer, including the provider, model, and API key.
|
|
462
|
-
This configuration is optional if you're registered on the [Intlayer Dashboard](https://intlayer.org/dashboard/project) using an access key. Intlayer will automatically manage the most efficient and cost-effective AI solution for your needs. Using the default options ensures better long-term maintainability as Intlayer continuously updates to use the most relevant models.
|
|
463
467
|
|
|
464
|
-
|
|
465
|
-
|
|
468
|
+
This configuration is optional if you are registered on the [Intlayer Dashboard](https://intlayer.org/dashboard/project) using an access key. Intlayer will automatically manage the most efficient and cost-effective AI solution for your needs. Using the default options ensures better long-term maintainability as Intlayer continuously updates to use the most relevant models.
|
|
469
|
+
|
|
470
|
+
If you prefer to use your own API key or specific model, you can define your custom AI configuration.
|
|
471
|
+
This AI configuration will be used globally across your Intlayer environment. CLI commands will use these settings as defaults for the commands (e.g. `fill`), as well as the SDK, Visual Editor, and CMS. You can override these default values for specific use cases using command parameters.
|
|
472
|
+
|
|
466
473
|
Intlayer supports multiple AI providers for enhanced flexibility and choice. Currently supported providers are:
|
|
467
474
|
|
|
468
475
|
- **OpenAI** (default)
|
|
@@ -475,7 +482,6 @@ Intlayer supports multiple AI providers for enhanced flexibility and choice. Cur
|
|
|
475
482
|
#### Properties
|
|
476
483
|
|
|
477
484
|
- **provider**:
|
|
478
|
-
|
|
479
485
|
- _Type_: `string`
|
|
480
486
|
- _Default_: `'openai'`
|
|
481
487
|
- _Description_: The provider to use for the AI features of Intlayer.
|
|
@@ -484,7 +490,6 @@ Intlayer supports multiple AI providers for enhanced flexibility and choice. Cur
|
|
|
484
490
|
- _Note_: Different providers may require different API keys and have different pricing models.
|
|
485
491
|
|
|
486
492
|
- **model**:
|
|
487
|
-
|
|
488
493
|
- _Type_: `string`
|
|
489
494
|
- _Default_: None
|
|
490
495
|
- _Description_: The model to use for the AI features of Intlayer.
|
|
@@ -492,7 +497,6 @@ Intlayer supports multiple AI providers for enhanced flexibility and choice. Cur
|
|
|
492
497
|
- _Note_: The specific model to use varies by provider.
|
|
493
498
|
|
|
494
499
|
- **temperature**:
|
|
495
|
-
|
|
496
500
|
- _Type_: `number`
|
|
497
501
|
- _Default_: None
|
|
498
502
|
- _Description_: The temperature controls the randomness of the AI's responses.
|
|
@@ -500,17 +504,16 @@ Intlayer supports multiple AI providers for enhanced flexibility and choice. Cur
|
|
|
500
504
|
- _Note_: A higher temperature will make the AI more creative and less predictable.
|
|
501
505
|
|
|
502
506
|
- **apiKey**:
|
|
503
|
-
|
|
504
507
|
- _Type_: `string`
|
|
505
508
|
- _Default_: None
|
|
506
509
|
- _Description_: Your API key for the selected provider.
|
|
507
510
|
- _Example_: `process.env.OPENAI_API_KEY`
|
|
508
|
-
- _Note_: Important: API keys should be kept
|
|
511
|
+
- _Note_: Important: API keys should be kept confidential and not shared publicly. Please ensure they are stored securely, such as in environment variables.
|
|
509
512
|
|
|
510
513
|
- **applicationContext**:
|
|
511
514
|
- _Type_: `string`
|
|
512
515
|
- _Default_: None
|
|
513
|
-
- _Description_: Provides additional context about your application to the AI model,
|
|
516
|
+
- _Description_: Provides additional context about your application to the AI model, assisting it in generating more accurate and contextually appropriate translations. This can include information about your app's domain, target audience, tone, or specific terminology.
|
|
514
517
|
|
|
515
518
|
### Build Configuration
|
|
516
519
|
|
|
@@ -525,33 +528,32 @@ Build options apply to the `@intlayer/babel` and `@intlayer/swc` plugins.
|
|
|
525
528
|
#### Properties
|
|
526
529
|
|
|
527
530
|
- **optimize**:
|
|
528
|
-
|
|
529
531
|
- _Type_: `boolean`
|
|
530
532
|
- _Default_: `process.env.NODE_ENV === 'production'`
|
|
531
533
|
- _Description_: Controls whether the build should be optimised.
|
|
532
534
|
- _Example_: `true`
|
|
533
|
-
- _Note_: When enabled, Intlayer will replace all calls of dictionaries to optimise chunking. That way the final bundle will import only the dictionaries that are used. All imports will
|
|
535
|
+
- _Note_: When enabled, Intlayer will replace all calls of dictionaries to optimise chunking. That way the final bundle will import only the dictionaries that are used. All imports will remain as static imports to avoid async processing when loading the dictionaries.
|
|
534
536
|
- _Note_: Intlayer will replace all calls of `useIntlayer` with the defined mode by the `importMode` option and `getIntlayer` with `getDictionary`.
|
|
535
537
|
- _Note_: This option relies on the `@intlayer/babel` and `@intlayer/swc` plugins.
|
|
536
538
|
- _Note_: Ensure all keys are declared statically in the `useIntlayer` calls. e.g. `useIntlayer('navbar')`.
|
|
537
539
|
|
|
538
540
|
- **importMode**:
|
|
539
|
-
|
|
540
|
-
- _Type_: `'static' | 'dynamic' | 'async'`
|
|
541
|
+
- _Type_: `'static' | 'dynamic' | 'live'`
|
|
541
542
|
- _Default_: `'static'`
|
|
542
543
|
- _Description_: Controls how dictionaries are imported.
|
|
543
544
|
- _Example_: `'dynamic'`
|
|
544
545
|
- _Note_: Available modes:
|
|
545
546
|
- "static": Dictionaries are imported statically. Replaces `useIntlayer` with `useDictionary`.
|
|
546
547
|
- "dynamic": Dictionaries are imported dynamically using Suspense. Replaces `useIntlayer` with `useDictionaryDynamic`.
|
|
547
|
-
- "
|
|
548
|
-
- _Note_: Dynamic imports rely on Suspense and may slightly
|
|
549
|
-
- _Note_: If disabled all locales will be loaded at once, even if they are not used.
|
|
548
|
+
- "live": Dictionaries are fetched dynamically using the live sync API. Replaces `useIntlayer` with `useDictionaryFetch`.
|
|
549
|
+
- _Note_: Dynamic imports rely on Suspense and may slightly affect rendering performance.
|
|
550
|
+
- _Note_: If disabled, all locales will be loaded at once, even if they are not used.
|
|
550
551
|
- _Note_: This option relies on the `@intlayer/babel` and `@intlayer/swc` plugins.
|
|
551
|
-
- _Note_: Ensure all keys are declared statically in the `useIntlayer` calls
|
|
552
|
+
- _Note_: Ensure all keys are declared statically in the `useIntlayer` calls, e.g. `useIntlayer('navbar')`.
|
|
552
553
|
- _Note_: This option will be ignored if `optimize` is disabled.
|
|
553
|
-
- _Note_:
|
|
554
|
-
- _Note_:
|
|
554
|
+
- _Note_: If set to "live", only the dictionaries that include remote content and are flagged as "live" will be transformed into live mode. Others will be imported dynamically as "dynamic" mode to optimise the number of fetch queries and load performance.
|
|
555
|
+
- _Note_: Live mode will use the live sync API to fetch the dictionaries. If the API call fails, the dictionaries will be imported dynamically as "dynamic" mode.
|
|
556
|
+
- _Note_: This option will not affect the `getIntlayer`, `getDictionary`, `useDictionary`, `useDictionaryAsync` and `useDictionaryDynamic` functions.
|
|
555
557
|
|
|
556
558
|
- **traversePattern**:
|
|
557
559
|
- _Type_: `string[]`
|
|
@@ -564,4 +566,10 @@ Build options apply to the `@intlayer/babel` and `@intlayer/swc` plugins.
|
|
|
564
566
|
|
|
565
567
|
## Doc History
|
|
566
568
|
|
|
567
|
-
|
|
569
|
+
| Version | Date | Changes |
|
|
570
|
+
| ------- | ---------- | ----------------------------------------------------------------------------------------- |
|
|
571
|
+
| 6.0.0 | 2025-09-16 | Add `live` import mode |
|
|
572
|
+
| 6.0.0 | 2025-09-04 | Replace `hotReload` field with `liveSync` and add `liveSyncPort` and `liveSyncURL` fields |
|
|
573
|
+
| 5.6.1 | 2025-07-25 | Replace `activateDynamicImport` with `importMode` option |
|
|
574
|
+
| 5.6.0 | 2025-07-13 | Change default contentDir from `['src']` to `['.']` |
|
|
575
|
+
| 5.5.11 | 2025-06-29 | Add `docs` commands |
|