@intlayer/docs 7.5.11 → 7.5.13
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/uk/compiler_vs_declarative_i18n.md +224 -0
- package/blog/uk/i18n_using_next-i18next.md +1086 -0
- package/blog/uk/i18n_using_next-intl.md +760 -0
- package/blog/uk/index.md +69 -0
- package/blog/uk/internationalization_and_SEO.md +273 -0
- package/blog/uk/intlayer_with_i18next.md +211 -0
- package/blog/uk/intlayer_with_next-i18next.md +202 -0
- package/blog/uk/intlayer_with_next-intl.md +203 -0
- package/blog/uk/intlayer_with_react-i18next.md +200 -0
- package/blog/uk/intlayer_with_react-intl.md +202 -0
- package/blog/uk/intlayer_with_vue-i18n.md +206 -0
- package/blog/uk/l10n_platform_alternative/Lokalise.md +80 -0
- package/blog/uk/l10n_platform_alternative/crowdin.md +80 -0
- package/blog/uk/l10n_platform_alternative/phrase.md +78 -0
- package/blog/uk/list_i18n_technologies/CMS/drupal.md +143 -0
- package/blog/uk/list_i18n_technologies/CMS/wix.md +167 -0
- package/blog/uk/list_i18n_technologies/CMS/wordpress.md +189 -0
- package/blog/uk/list_i18n_technologies/frameworks/angular.md +125 -0
- package/blog/uk/list_i18n_technologies/frameworks/flutter.md +128 -0
- package/blog/uk/list_i18n_technologies/frameworks/react-native.md +217 -0
- package/blog/uk/list_i18n_technologies/frameworks/react.md +155 -0
- package/blog/uk/list_i18n_technologies/frameworks/svelte.md +145 -0
- package/blog/uk/list_i18n_technologies/frameworks/vue.md +144 -0
- package/blog/uk/next-i18next_vs_next-intl_vs_intlayer.md +1499 -0
- package/blog/uk/nextjs-multilingual-seo-comparison.md +360 -0
- package/blog/uk/rag_powered_documentation_assistant.md +288 -0
- package/blog/uk/react-i18next_vs_react-intl_vs_intlayer.md +164 -0
- package/blog/uk/vue-i18n_vs_intlayer.md +279 -0
- package/blog/uk/what_is_internationalization.md +167 -0
- 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 +218 -99
- package/dist/cjs/generated/docs.entry.cjs.map +1 -1
- package/dist/cjs/generated/frequentQuestions.entry.cjs +50 -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 +218 -99
- package/dist/esm/generated/docs.entry.mjs.map +1 -1
- package/dist/esm/generated/frequentQuestions.entry.mjs +50 -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 +1 -0
- package/dist/types/generated/docs.entry.d.ts.map +1 -1
- package/dist/types/generated/frequentQuestions.entry.d.ts +1 -0
- 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/configuration.md +6 -1
- package/docs/ar/dictionary/content_file.md +6 -1
- 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/configuration.md +6 -1
- package/docs/de/dictionary/content_file.md +6 -1
- 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/configuration.md +6 -1
- package/docs/en/dictionary/content_file.md +6 -1
- 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/configuration.md +6 -1
- package/docs/en-GB/dictionary/content_file.md +3 -1
- 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/configuration.md +6 -1
- package/docs/es/dictionary/content_file.md +6 -1
- 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/configuration.md +6 -1
- package/docs/fr/dictionary/content_file.md +3 -1
- 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/configuration.md +6 -1
- package/docs/hi/dictionary/content_file.md +3 -1
- 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/configuration.md +6 -1
- package/docs/id/dictionary/content_file.md +3 -1
- 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/configuration.md +6 -1
- package/docs/it/dictionary/content_file.md +3 -1
- 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/configuration.md +6 -1
- package/docs/ja/dictionary/content_file.md +3 -1
- 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/configuration.md +6 -1
- package/docs/ko/dictionary/content_file.md +3 -1
- 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/configuration.md +3 -1
- package/docs/pl/dictionary/content_file.md +3 -1
- 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/configuration.md +6 -1
- package/docs/pt/dictionary/content_file.md +3 -1
- 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/configuration.md +6 -1
- package/docs/ru/dictionary/content_file.md +6 -1
- 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/configuration.md +6 -1
- package/docs/tr/dictionary/content_file.md +3 -1
- 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/CI_CD.md +198 -0
- package/docs/uk/autoFill.md +307 -0
- package/docs/uk/bundle_optimization.md +185 -0
- package/docs/uk/cli/build.md +64 -0
- package/docs/uk/cli/ci.md +137 -0
- package/docs/uk/cli/configuration.md +63 -0
- package/docs/uk/cli/debug.md +46 -0
- package/docs/uk/cli/doc-review.md +43 -0
- package/docs/uk/cli/doc-translate.md +132 -0
- package/docs/uk/cli/editor.md +28 -0
- package/docs/uk/cli/fill.md +130 -0
- package/docs/uk/cli/index.md +190 -0
- package/docs/uk/cli/init.md +84 -0
- package/docs/uk/cli/list.md +90 -0
- package/docs/uk/cli/list_projects.md +128 -0
- package/docs/uk/cli/live.md +41 -0
- package/docs/uk/cli/login.md +157 -0
- package/docs/uk/cli/pull.md +78 -0
- package/docs/uk/cli/push.md +98 -0
- package/docs/uk/cli/sdk.md +71 -0
- package/docs/uk/cli/test.md +76 -0
- package/docs/uk/cli/transform.md +65 -0
- package/docs/uk/cli/version.md +24 -0
- package/docs/uk/cli/watch.md +37 -0
- package/docs/uk/compiler.md +133 -0
- package/docs/uk/component_i18n.md +194 -0
- package/docs/uk/configuration.md +742 -0
- package/docs/uk/dictionary/condition.md +237 -0
- package/docs/uk/dictionary/content_file.md +1134 -0
- package/docs/uk/dictionary/enumeration.md +245 -0
- package/docs/uk/dictionary/file.md +232 -0
- package/docs/uk/dictionary/function_fetching.md +212 -0
- package/docs/uk/dictionary/gender.md +273 -0
- package/docs/uk/dictionary/insertion.md +187 -0
- package/docs/uk/dictionary/markdown.md +383 -0
- package/docs/uk/dictionary/nesting.md +273 -0
- package/docs/uk/dictionary/translation.md +332 -0
- package/docs/uk/formatters.md +595 -0
- package/docs/uk/how_works_intlayer.md +256 -0
- package/docs/uk/index.md +175 -0
- package/docs/uk/interest_of_intlayer.md +297 -0
- package/docs/uk/intlayer_CMS.md +569 -0
- package/docs/uk/intlayer_visual_editor.md +292 -0
- package/docs/uk/intlayer_with_angular.md +710 -0
- package/docs/uk/intlayer_with_astro.md +256 -0
- package/docs/uk/intlayer_with_create_react_app.md +1258 -0
- package/docs/uk/intlayer_with_express.md +429 -0
- package/docs/uk/intlayer_with_fastify.md +446 -0
- package/docs/uk/intlayer_with_lynx+react.md +548 -0
- package/docs/uk/intlayer_with_nestjs.md +283 -0
- package/docs/uk/intlayer_with_next-i18next.md +640 -0
- package/docs/uk/intlayer_with_next-intl.md +456 -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_nextjs_page_router.md +1541 -0
- package/docs/uk/intlayer_with_nuxt.md +711 -0
- package/docs/uk/intlayer_with_react_native+expo.md +715 -0
- package/docs/uk/intlayer_with_react_router_v7.md +600 -0
- package/docs/uk/intlayer_with_react_router_v7_fs_routes.md +669 -0
- package/docs/uk/intlayer_with_svelte_kit.md +579 -0
- package/docs/uk/intlayer_with_tanstack.md +818 -0
- package/docs/uk/intlayer_with_vite+preact.md +1748 -0
- package/docs/uk/intlayer_with_vite+react.md +1449 -0
- package/docs/uk/intlayer_with_vite+solid.md +302 -0
- package/docs/uk/intlayer_with_vite+svelte.md +520 -0
- package/docs/uk/intlayer_with_vite+vue.md +1113 -0
- package/docs/uk/introduction.md +222 -0
- package/docs/uk/locale_mapper.md +242 -0
- package/docs/uk/mcp_server.md +211 -0
- package/docs/uk/packages/express-intlayer/t.md +465 -0
- package/docs/uk/packages/intlayer/getConfiguration.md +145 -0
- package/docs/uk/packages/intlayer/getEnumeration.md +159 -0
- package/docs/uk/packages/intlayer/getHTMLTextDir.md +121 -0
- package/docs/uk/packages/intlayer/getLocaleLang.md +81 -0
- package/docs/uk/packages/intlayer/getLocaleName.md +135 -0
- package/docs/uk/packages/intlayer/getLocalizedUrl.md +338 -0
- package/docs/uk/packages/intlayer/getMultilingualUrls.md +359 -0
- package/docs/uk/packages/intlayer/getPathWithoutLocale.md +75 -0
- package/docs/uk/packages/intlayer/getPrefix.md +213 -0
- package/docs/uk/packages/intlayer/getTranslation.md +190 -0
- package/docs/uk/packages/intlayer/getTranslationContent.md +189 -0
- package/docs/uk/packages/next-intlayer/t.md +365 -0
- package/docs/uk/packages/next-intlayer/useDictionary.md +276 -0
- package/docs/uk/packages/next-intlayer/useIntlayer.md +263 -0
- package/docs/uk/packages/next-intlayer/useLocale.md +166 -0
- package/docs/uk/packages/react-intlayer/t.md +311 -0
- package/docs/uk/packages/react-intlayer/useDictionary.md +295 -0
- package/docs/uk/packages/react-intlayer/useI18n.md +250 -0
- package/docs/uk/packages/react-intlayer/useIntlayer.md +251 -0
- package/docs/uk/packages/react-intlayer/useLocale.md +210 -0
- package/docs/uk/per_locale_file.md +345 -0
- package/docs/uk/plugins/sync-json.md +398 -0
- package/docs/uk/readme.md +265 -0
- package/docs/uk/releases/v6.md +305 -0
- package/docs/uk/releases/v7.md +624 -0
- package/docs/uk/roadmap.md +346 -0
- package/docs/uk/testing.md +204 -0
- package/docs/uk/vs_code_extension.md +133 -0
- package/docs/vi/configuration.md +6 -1
- package/docs/vi/dictionary/content_file.md +6 -1
- 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/configuration.md +6 -1
- package/docs/zh/dictionary/content_file.md +6 -1
- 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/ar/error-vite-env-only.md +77 -0
- package/frequent_questions/de/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/de/error-vite-env-only.md +77 -0
- package/frequent_questions/en/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/en/error-vite-env-only.md +77 -0
- package/frequent_questions/en-GB/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/en-GB/error-vite-env-only.md +77 -0
- package/frequent_questions/es/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/es/error-vite-env-only.md +76 -0
- package/frequent_questions/fr/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/fr/error-vite-env-only.md +77 -0
- package/frequent_questions/hi/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/hi/error-vite-env-only.md +77 -0
- package/frequent_questions/id/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/id/error-vite-env-only.md +77 -0
- package/frequent_questions/it/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/it/error-vite-env-only.md +77 -0
- package/frequent_questions/ja/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/ja/error-vite-env-only.md +77 -0
- package/frequent_questions/ko/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/ko/error-vite-env-only.md +77 -0
- package/frequent_questions/pl/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/pl/error-vite-env-only.md +77 -0
- package/frequent_questions/pt/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/pt/error-vite-env-only.md +77 -0
- package/frequent_questions/ru/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/ru/error-vite-env-only.md +77 -0
- package/frequent_questions/tr/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/tr/error-vite-env-only.md +77 -0
- package/frequent_questions/uk/SSR_Next_no_[locale].md +104 -0
- package/frequent_questions/uk/array_as_content_declaration.md +72 -0
- package/frequent_questions/uk/build_dictionaries.md +58 -0
- package/frequent_questions/uk/build_error_CI_CD.md +74 -0
- package/frequent_questions/uk/bun_set_up.md +53 -0
- package/frequent_questions/uk/customized_locale_list.md +64 -0
- package/frequent_questions/uk/domain_routing.md +113 -0
- package/frequent_questions/uk/error-vite-env-only.md +77 -0
- package/frequent_questions/uk/esbuild_error.md +29 -0
- package/frequent_questions/uk/get_locale_cookie.md +142 -0
- package/frequent_questions/uk/intlayer_command_undefined.md +155 -0
- package/frequent_questions/uk/locale_incorect_in_url.md +73 -0
- package/frequent_questions/uk/package_version_error.md +181 -0
- package/frequent_questions/uk/static_rendering.md +44 -0
- package/frequent_questions/uk/translated_path_url.md +55 -0
- package/frequent_questions/uk/unknown_command.md +97 -0
- package/frequent_questions/vi/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/vi/error-vite-env-only.md +77 -0
- package/frequent_questions/zh/SSR_Next_no_[locale].md +1 -1
- package/frequent_questions/zh/error-vite-env-only.md +77 -0
- package/legal/uk/privacy_notice.md +83 -0
- package/legal/uk/terms_of_service.md +55 -0
- package/package.json +6 -6
- package/src/generated/blog.entry.ts +29 -0
- package/src/generated/docs.entry.ts +119 -0
- package/src/generated/frequentQuestions.entry.ts +35 -0
- package/src/generated/legal.entry.ts +2 -0
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
---
|
|
2
|
+
createdAt: 2026-01-11
|
|
3
|
+
updatedAt: 2026-01-11
|
|
4
|
+
title: "`vite-env-only` & Intlayer – yanlış pozitif `node:fs` reddedildi hatası"
|
|
5
|
+
description: "vite-env-only'nin Intlayer + React-Router + Vite ile `node:fs` importunu neden reddettiğini ve yapılması gerekenleri."
|
|
6
|
+
keywords:
|
|
7
|
+
- intlayer
|
|
8
|
+
- vite
|
|
9
|
+
- react-router
|
|
10
|
+
- vite-env-only
|
|
11
|
+
- node:fs
|
|
12
|
+
- import reddedildi
|
|
13
|
+
- alias
|
|
14
|
+
- client bundle
|
|
15
|
+
slugs:
|
|
16
|
+
- frequent-questions
|
|
17
|
+
- vite-env-only-node-fs-false-positive
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
# vite-env-only Intlayer ile `node:fs`'i reddediyor
|
|
21
|
+
|
|
22
|
+
Eğer **vite-env-only** eklentisini kullandıysanız (eski React-Router v7 önerilerinde belirtildiği gibi) ve şu hatayı görüyorsanız:
|
|
23
|
+
|
|
24
|
+
```bash
|
|
25
|
+
|
|
26
|
+
Error: [vite-env-only] Import denied
|
|
27
|
+
|
|
28
|
+
* Denied by specifier pattern: /^node:/
|
|
29
|
+
* Importer: index.html
|
|
30
|
+
* Import: "node:fs"
|
|
31
|
+
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
…istemci paketinizde **`node:fs` olmasa bile**, bu bir **yanlış pozitif**.
|
|
35
|
+
|
|
36
|
+
## Buna ne sebep oluyor
|
|
37
|
+
|
|
38
|
+
`vite-env-only`, Vite grafik çözümlemesinin **erken aşamasında** Babel tabanlı bir kontrol çalıştırır, _şundan önce_:
|
|
39
|
+
|
|
40
|
+
- aliasing (Intlayer’ın tarayıcı vs node eşlemeleri dahil),
|
|
41
|
+
- kullanılmayan kodun kaldırılması (dead-code elimination),
|
|
42
|
+
- SSR ile istemci çözümlemesi,
|
|
43
|
+
- React-Router gibi sanal modüller.
|
|
44
|
+
|
|
45
|
+
Intlayer paketleri hem Node hem tarayıcı üzerinde çalışabilecek kod içerir. Bir _ara_ aşamada, `node:fs` gibi bir Node yerleşiği grafikte Vite bunun istemci derlemesinden kaldırmasından **önce** görünebilir. `vite-env-only` bunu görür ve nihai paket bunu içermese bile hemen hata verir.
|
|
46
|
+
|
|
47
|
+
## React-Router ve Sunucu Modülleri
|
|
48
|
+
|
|
49
|
+
React-Router dokümantasyonunda **sunucu modülü konvansiyonları** ile ilgili olarak
|
|
50
|
+
(https://reactrouter.com/api/framework-conventions/server-modules), ekip, sunucuya özel importların istemci paketine sızmasını önlemek için **açıkça `vite-env-only` kullanmayı önerir**.
|
|
51
|
+
|
|
52
|
+
Ancak bu konvansiyonlar, sunucuya özel kodu kaldırmak için Vite’in aliasing’ine, conditional exports'ına ve tree-shaking’ine dayanır. Alias’lama ve conditional exports zaten uygulanmış olsa da, bazı Node tabanlı yardımcılar bu aşamada `@intlayer/core` gibi paketlerde hâlâ mevcut olabilir (istemcide hiç import edilmemiş olsalar bile). Çünkü tree-shaking henüz çalışmadığından, bu fonksiyonlar hâlâ Babel tarafından parse edilir ve `vite-env-only` onların `node:` importlarını tespit edip yanlış pozitif bir hata verir — oysa bunlar nihai istemci paketinden doğru şekilde temizlenir.
|
|
53
|
+
|
|
54
|
+
## Nasıl düzeltilecek / geçici çözümler
|
|
55
|
+
|
|
56
|
+
### Önerilen: `vite-env-only`'ı kaldırın
|
|
57
|
+
|
|
58
|
+
Eklentiyi basitçe kaldırın. Birçok durumda buna gerek yok — Vite kendi çözümlemesiyle istemci ve sunucu importlarını zaten yönetir.
|
|
59
|
+
|
|
60
|
+
Bu, Intlayer'da değişiklik yapmadan yanlış `node:fs` reddini düzeltir.
|
|
61
|
+
|
|
62
|
+
### Bunun yerine son yapıyı doğrulayın
|
|
63
|
+
|
|
64
|
+
İstemci paketlerinde Node yerleşiklerinin bulunmadığından hâlâ emin olmak istiyorsanız, bunu **build sonrası** yapın, örn:
|
|
65
|
+
|
|
66
|
+
```bash
|
|
67
|
+
pnpm build
|
|
68
|
+
grep -R "node:" dist/
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
Eğer sonuç yoksa, istemci bundle'larınız temizdir.
|
|
72
|
+
|
|
73
|
+
## Özet
|
|
74
|
+
|
|
75
|
+
- `vite-env-only` çok erken kontrol ettiği için `node:fs` üzerinde hata verebilir.
|
|
76
|
+
- Vite + Intlayer + React-Router'ın server modules konvansiyonları genellikle yalnızca sunucuya ait referansları doğru şekilde kaldırır.
|
|
77
|
+
- Eklentiyi kaldırmak veya _nihai çıktıyı_ doğrulamak genellikle en iyi çözümdür.
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
---
|
|
2
|
+
createdAt: 2025-05-20
|
|
3
|
+
updatedAt: 2025-06-29
|
|
4
|
+
title: Чи можна використовувати Intlayer з Next.js без `[locale]` у шляху сторінки?
|
|
5
|
+
description: Дізнайтеся, як використовувати Intlayer з Next.js без `[locale]` у шляху сторінки.
|
|
6
|
+
keywords:
|
|
7
|
+
- locale
|
|
8
|
+
- path
|
|
9
|
+
- intlayer
|
|
10
|
+
- next.js
|
|
11
|
+
- vite
|
|
12
|
+
- framework
|
|
13
|
+
- middleware
|
|
14
|
+
- configuration
|
|
15
|
+
- prefixDefault
|
|
16
|
+
- noPrefix
|
|
17
|
+
slugs:
|
|
18
|
+
- frequent-questions
|
|
19
|
+
- next-no-locale-path
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
# Чи можна використовувати Intlayer з Next.js без `[locale]` у шляху сторінки?
|
|
23
|
+
|
|
24
|
+
Так — можна використовувати Intlayer з Next.js без `[locale]` у шляху сторінки. Однак цього не рекомендується робити, оскільки розділення сторінок по локалях дозволяє підвищити видимість за більшою кількістю ключових слів у пошукових системах. Крім того, це може вплинути на ваш SSR.
|
|
25
|
+
|
|
26
|
+
Якщо ви хочете це зробити, дотримуйтеся тих самих кроків, що описані в керівництві [Intlayer with Next.js](https://intlayer.org/doc/environment/nextjs),
|
|
27
|
+
|
|
28
|
+
- без `src/middleware.ts`
|
|
29
|
+
- без `generateStaticParams`
|
|
30
|
+
|
|
31
|
+
```tsx fileName="src/app/layout.tsx"
|
|
32
|
+
import type { FC, PropsWithChildren } from "react";
|
|
33
|
+
|
|
34
|
+
const LocaleLayout: FC<PropsWithChildren> = ({ children }) => (
|
|
35
|
+
<html lang={undefined} dir={undefined}>
|
|
36
|
+
<body className={inter.className}>{children}</body>
|
|
37
|
+
</html>
|
|
38
|
+
);
|
|
39
|
+
|
|
40
|
+
export default LocaleLayout;
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
```tsx fileName="src/app/page.tsx"
|
|
44
|
+
import type { FC } from "react";
|
|
45
|
+
import { ClientComponentExample } from "@components/ClientComponentExample";
|
|
46
|
+
import { ServerComponentExample } from "@components/ServerComponentExample";
|
|
47
|
+
import { PageContent } from "@components/pageContent";
|
|
48
|
+
import { type NextPageIntlayer, IntlayerClientProvider } from "next-intlayer";
|
|
49
|
+
import { IntlayerServerProvider } from "next-intlayer/server";
|
|
50
|
+
|
|
51
|
+
const Page: FC = () => {
|
|
52
|
+
return (
|
|
53
|
+
<IntlayerServerProvider>
|
|
54
|
+
<PageContent />
|
|
55
|
+
<ServerComponentExample />
|
|
56
|
+
|
|
57
|
+
<IntlayerClientProvider>
|
|
58
|
+
<ClientComponentExample />
|
|
59
|
+
</IntlayerClientProvider>
|
|
60
|
+
</IntlayerServerProvider>
|
|
61
|
+
);
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
export default Page;
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
```tsx fileName="src/component/pageContent.ts"
|
|
68
|
+
"use client";
|
|
69
|
+
|
|
70
|
+
import { type FC } from "react";
|
|
71
|
+
import { useIntlayer } from "next-intlayer";
|
|
72
|
+
import { useHTMLLanguage } from "@hooks/htmlTextDir";
|
|
73
|
+
|
|
74
|
+
const PageContent: FC = () => {
|
|
75
|
+
useHTMLLanguage();
|
|
76
|
+
const content = useIntlayer("page");
|
|
77
|
+
|
|
78
|
+
return (
|
|
79
|
+
<>
|
|
80
|
+
<p>{content.getStarted.main}</p>
|
|
81
|
+
<code>{content.getStarted.pageLink}</code>
|
|
82
|
+
</>
|
|
83
|
+
);
|
|
84
|
+
};
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
```tsx fileName="src/hooks/htmlTextDir.ts"
|
|
88
|
+
"use client";
|
|
89
|
+
|
|
90
|
+
import { useEffect } from "react";
|
|
91
|
+
import { getHTMLTextDir } from "intlayer";
|
|
92
|
+
import { useLocale } from "next-intlayer";
|
|
93
|
+
|
|
94
|
+
export const useHTMLLanguage = () => {
|
|
95
|
+
const { locale } = useLocale();
|
|
96
|
+
|
|
97
|
+
useEffect(() => {
|
|
98
|
+
if (!document) return;
|
|
99
|
+
|
|
100
|
+
document.documentElement.lang = locale;
|
|
101
|
+
document.documentElement.dir = getHTMLTextDir(locale);
|
|
102
|
+
}, [locale]);
|
|
103
|
+
};
|
|
104
|
+
```
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
---
|
|
2
|
+
createdAt: 2025-05-20
|
|
3
|
+
updatedAt: 2025-06-29
|
|
4
|
+
title: Чи можна використовувати масив як декларацію контенту?
|
|
5
|
+
description: Дізнайтеся, як використовувати масив як декларацію контенту.
|
|
6
|
+
keywords:
|
|
7
|
+
- масив
|
|
8
|
+
- вміст
|
|
9
|
+
- оголошення
|
|
10
|
+
- intlayer
|
|
11
|
+
slugs:
|
|
12
|
+
- frequent-questions
|
|
13
|
+
- array-as-content-declaration
|
|
14
|
+
---
|
|
15
|
+
|
|
16
|
+
# Чи можна використовувати масив як декларацію контенту?
|
|
17
|
+
|
|
18
|
+
Так — ви можете використовувати масив як декларацію контенту.
|
|
19
|
+
|
|
20
|
+
```ts
|
|
21
|
+
import { t, type Dictionary } from "intlayer";
|
|
22
|
+
|
|
23
|
+
const exampleContent = {
|
|
24
|
+
key: "example",
|
|
25
|
+
content: {
|
|
26
|
+
test: t({
|
|
27
|
+
uk: ["Тест", "Тест2", "Тест3"],
|
|
28
|
+
en: ["Test", "Test2", "Test3"],
|
|
29
|
+
fr: ["Test", "Test2", "Test3"],
|
|
30
|
+
es: ["Test", "Test2", "Test3"],
|
|
31
|
+
}),
|
|
32
|
+
},
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
export default exampleContent;
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
Далі ви можете використовувати контент ось так:
|
|
39
|
+
|
|
40
|
+
```tsx
|
|
41
|
+
import { useIntlayer } from "react-intlayer";
|
|
42
|
+
|
|
43
|
+
const Example = () => {
|
|
44
|
+
const content = useIntlayer("example");
|
|
45
|
+
|
|
46
|
+
return (
|
|
47
|
+
<div>
|
|
48
|
+
{content.test.map((item) => (
|
|
49
|
+
<div key={item.value}>{item}</div>
|
|
50
|
+
))}
|
|
51
|
+
</div>
|
|
52
|
+
);
|
|
53
|
+
};
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
```vue
|
|
57
|
+
<script setup lang="ts">
|
|
58
|
+
import { useIntlayer } from "vue-intlayer";
|
|
59
|
+
|
|
60
|
+
const content = useIntlayer("example");
|
|
61
|
+
</script>
|
|
62
|
+
|
|
63
|
+
<template>
|
|
64
|
+
<div>
|
|
65
|
+
<div v-for="item in content.test" :key="item.value">
|
|
66
|
+
{{ item }}
|
|
67
|
+
</div>
|
|
68
|
+
</div>
|
|
69
|
+
</template>
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
.value дозволяє отримати значення контенту, яке не обгорнуте в `IntlayerNode`.
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
---
|
|
2
|
+
createdAt: 2025-05-20
|
|
3
|
+
updatedAt: 2025-06-29
|
|
4
|
+
title: Як згенерувати словники?
|
|
5
|
+
description: Дізнайтеся, як згенерувати словники.
|
|
6
|
+
keywords:
|
|
7
|
+
- build
|
|
8
|
+
- словники
|
|
9
|
+
- intlayer
|
|
10
|
+
- команда
|
|
11
|
+
- watch
|
|
12
|
+
- vscode
|
|
13
|
+
- плагін
|
|
14
|
+
- framework
|
|
15
|
+
- next.js
|
|
16
|
+
- vite
|
|
17
|
+
slugs:
|
|
18
|
+
- frequent-questions
|
|
19
|
+
- build-dictionaries
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
# Build Dictionaries
|
|
23
|
+
|
|
24
|
+
## How to Build Dictionaries
|
|
25
|
+
|
|
26
|
+
Intlayer provides a command-line tool to build dictionaries.
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
npx intlayer dictionaries build
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
This command:
|
|
33
|
+
|
|
34
|
+
- Scans all content declaration files (`.content.{ts,tsx,js,mjs,cjs,json,...}`) in your project.
|
|
35
|
+
- Generates dictionaries and stores them in the `.intlayer/dictionary` folder.
|
|
36
|
+
|
|
37
|
+
### Watch Mode
|
|
38
|
+
|
|
39
|
+
Якщо ви хочете автоматично оновлювати словники при внесенні змін у файли декларацій контенту, виконайте таку команду:
|
|
40
|
+
|
|
41
|
+
```bash
|
|
42
|
+
npx intlayer dictionaries build --watch
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
У цьому режимі Intlayer скануватиме та будуватиме словники щоразу, коли вносяться зміни у файли декларацій контенту, і автоматично оновлюватиме папку `.intlayer/dictionary`.
|
|
46
|
+
|
|
47
|
+
### Використання розширення VSCode
|
|
48
|
+
|
|
49
|
+
Ви також можете використовувати [розширення Intlayer для VSCode](https://github.com/aymericzip/intlayer/tree/main/docs/uk/vs_code_extension.md), щоб покращити роботу з Intlayer у VSCode.
|
|
50
|
+
|
|
51
|
+
### Використання плагіна для вашого улюбленого фреймворка
|
|
52
|
+
|
|
53
|
+
Якщо ви використовуєте фреймворк на кшталт Next.js (Webpack / Turbopack), Vite, React Native, Lynx тощо, Intlayer надає плагін, який ви можете використати для інтеграції Intlayer у ваш додаток.
|
|
54
|
+
|
|
55
|
+
Intlayer збирає словники перед збіркою вашого додатка.
|
|
56
|
+
Аналогічно, у режимі розробки Intlayer стежитиме за змінами у файлах декларації контенту й автоматично перебудовуватиме словники.
|
|
57
|
+
|
|
58
|
+
Тому зверніться до документації, специфічної для вашого фреймворку, щоб дізнатися, як інтегрувати плагін.
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
---
|
|
2
|
+
createdAt: 2025-05-20
|
|
3
|
+
updatedAt: 2025-06-29
|
|
4
|
+
title: Помилка збірки в CI/CD
|
|
5
|
+
description: Дізнайтеся, як виправити помилки збірки, що виникають у середовищах CI/CD.
|
|
6
|
+
keywords:
|
|
7
|
+
- build
|
|
8
|
+
- error
|
|
9
|
+
- ci
|
|
10
|
+
- cd
|
|
11
|
+
- pipeline
|
|
12
|
+
- intlayer
|
|
13
|
+
- dictionaries
|
|
14
|
+
- next.js
|
|
15
|
+
- prebuild
|
|
16
|
+
- automation
|
|
17
|
+
slugs:
|
|
18
|
+
- frequent-questions
|
|
19
|
+
- build-error-ci-cd
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
# Помилка під час збірки в CI/CD
|
|
23
|
+
|
|
24
|
+
Якщо ви отримуєте таку помилку в Next.js:
|
|
25
|
+
|
|
26
|
+
```text
|
|
27
|
+
Error: An error occurred in the Server Components render. The specific message is omitted in production builds to avoid leaking sensitive details. A digest property is included on this error instance which may provide additional details about the nature of the error
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
Ось кілька рішень:
|
|
31
|
+
|
|
32
|
+
## 1. Відсутні словники
|
|
33
|
+
|
|
34
|
+
Переконайтеся, що dictionaries будуються під час етапу збірки.
|
|
35
|
+
|
|
36
|
+
Часто збірка працює локально, але не в CI/CD. Причина в тому, що локально каталог `.intlayer` присутній, а в CI/CD його немає, бо він виключений із збірки.
|
|
37
|
+
|
|
38
|
+
Ви можете виправити це, додавши скрипт prebuild у `package.json` вашого проєкту.
|
|
39
|
+
|
|
40
|
+
```json5 fileName=package.json
|
|
41
|
+
{
|
|
42
|
+
// інше ...
|
|
43
|
+
"scripts": {
|
|
44
|
+
"prebuild": "npx intlayer dictionaries build", // Виконається перед збіркою
|
|
45
|
+
"build": "next build",
|
|
46
|
+
},
|
|
47
|
+
}
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
> Зауважте, що якщо ви використовуєте функцію `withIntlayer`, або еквівалентний bundler plugin для вашого фреймворку, скрипт prebuild буде виконаний перед збіркою.
|
|
51
|
+
|
|
52
|
+
## 2. Відсутні змінні середовища під час збірки / виконання
|
|
53
|
+
|
|
54
|
+
У контейнері або на платформі з автоматичним деплоєм рекомендується виключати файл `.env` з процесу збірки.
|
|
55
|
+
|
|
56
|
+
```text fileName=".gitignore or .dockerignore"
|
|
57
|
+
# Змінні середовища
|
|
58
|
+
.env
|
|
59
|
+
**/.env
|
|
60
|
+
.env.*
|
|
61
|
+
**/.env.*
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
Якщо ваші змінні середовища недоступні під час збірки, буде викинута помилка.
|
|
65
|
+
|
|
66
|
+
```ts
|
|
67
|
+
import { Metadata } from "next";
|
|
68
|
+
|
|
69
|
+
export const generateMetadata = async ({ params }): Promise<Metadata> => ({
|
|
70
|
+
metadataBase: new URL(process.env.NEXT_PUBLIC_URL),
|
|
71
|
+
});
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
Ймовірно, це не пов'язано з Intlayer. Тому перевірте свої змінні середовища під час збірки на вашій CI/CD-платформі.
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
---
|
|
2
|
+
createdAt: 2025-05-20
|
|
3
|
+
updatedAt: 2025-06-29
|
|
4
|
+
title: Отримую помилку module not found при використанні bun
|
|
5
|
+
description: Виправлення помилки при використанні bun.
|
|
6
|
+
keywords:
|
|
7
|
+
- bun
|
|
8
|
+
- модуль не знайдено
|
|
9
|
+
- intlayer
|
|
10
|
+
- конфігурація
|
|
11
|
+
- пакетний менеджер
|
|
12
|
+
slugs:
|
|
13
|
+
- frequent-questions
|
|
14
|
+
- bun-set-up
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
# Отримую помилку 'module not found' при використанні bun
|
|
18
|
+
|
|
19
|
+
## Опис проблеми
|
|
20
|
+
|
|
21
|
+
При використанні bun ви можете зіткнутися з помилкою на кшталт цієї:
|
|
22
|
+
|
|
23
|
+
```bash
|
|
24
|
+
Cannot find package 'intlayer' from '/workspace/packages/@intlayer/config/dist/cjs/utils/ESMxCJSHelpers.cjs' undefined
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## Причина
|
|
28
|
+
|
|
29
|
+
Intlayer використовує `require` внутрішньо. А bun обмежує область дії функції `require`, через що вона резолвить лише пакети пакета `@intlayer/config`, а не весь проєкт.
|
|
30
|
+
|
|
31
|
+
## Рішення
|
|
32
|
+
|
|
33
|
+
### Надайте функцію `require` у конфігурації
|
|
34
|
+
|
|
35
|
+
```ts
|
|
36
|
+
const config: IntlayerConfig = {
|
|
37
|
+
build: {
|
|
38
|
+
require,
|
|
39
|
+
},
|
|
40
|
+
};
|
|
41
|
+
|
|
42
|
+
export default config;
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
```ts fileName="next.config.ts" codeFormat="typescript"
|
|
46
|
+
import { withIntlayer } from "next-intlayer/server";
|
|
47
|
+
|
|
48
|
+
const configuration = withIntlayer({
|
|
49
|
+
require,
|
|
50
|
+
});
|
|
51
|
+
|
|
52
|
+
export default configuration;
|
|
53
|
+
```
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
---
|
|
2
|
+
createdAt: 2025-05-20
|
|
3
|
+
updatedAt: 2025-06-29
|
|
4
|
+
title: Як налаштувати список локалей?
|
|
5
|
+
description: Дізнайтеся, як налаштувати список локалей.
|
|
6
|
+
keywords:
|
|
7
|
+
- локалі
|
|
8
|
+
- список
|
|
9
|
+
- intlayer
|
|
10
|
+
- конфігурація
|
|
11
|
+
- availableLocales
|
|
12
|
+
- defaultLocale
|
|
13
|
+
- useLocale
|
|
14
|
+
- hook
|
|
15
|
+
- локаль
|
|
16
|
+
- список
|
|
17
|
+
slugs:
|
|
18
|
+
- frequent-questions
|
|
19
|
+
- customized-locale-list
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
# Чи можна заблокувати певну мову, наприклад англійську? Я додаю англійську у свої словники, але поки не хочу, щоб англійська була доступна на сайті
|
|
23
|
+
|
|
24
|
+
Так, ви можете заблокувати певну мову, наприклад англійську, використавши опцію `availableLocales` у конфігурації Intlayer.
|
|
25
|
+
|
|
26
|
+
```ts
|
|
27
|
+
import { IntlayerConfig } from "intlayer";
|
|
28
|
+
|
|
29
|
+
const config: IntlayerConfig = {
|
|
30
|
+
locales: [Locales.FRENCH, Locales.SPANISH, Locales.ENGLISH],
|
|
31
|
+
availableLocales: [Locales.FRENCH, Locales.SPANISH],
|
|
32
|
+
defaultLocale: Locales.FRENCH,
|
|
33
|
+
};
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
або
|
|
37
|
+
|
|
38
|
+
```ts
|
|
39
|
+
import { IntlayerConfig } from "intlayer";
|
|
40
|
+
|
|
41
|
+
const locales = [Locales.FRENCH, Locales.SPANISH, Locales.ENGLISH];
|
|
42
|
+
|
|
43
|
+
const config: IntlayerConfig = {
|
|
44
|
+
locales,
|
|
45
|
+
availableLocales: locales.filter((locale) => locale !== Locales.ENGLISH),
|
|
46
|
+
defaultLocale: Locales.FRENCH,
|
|
47
|
+
};
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
Ця конфігурація змінить типи вашої функції `t()` так, щоб вони включали лише доступні локалі.
|
|
51
|
+
|
|
52
|
+
Опція availableLocales є необов'язковою — якщо ви її не вкажете, будуть доступні всі локалі.
|
|
53
|
+
|
|
54
|
+
Увага: усі локалі, включені в опцію `availableLocales`, повинні бути також включені в опцію `locales`.
|
|
55
|
+
|
|
56
|
+
Зауважте, що якщо ви використовуєте хук `useLocale`, опція `availableLocales` буде використана для встановлення доступу до списку локалей.
|
|
57
|
+
|
|
58
|
+
```ts
|
|
59
|
+
import { useLocale } from "react-intlayer";
|
|
60
|
+
|
|
61
|
+
const { availableLocales } = useLocale();
|
|
62
|
+
|
|
63
|
+
console.log(availableLocales); // Виведе: [Locales.FRENCH, Locales.SPANISH]
|
|
64
|
+
```
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
---
|
|
2
|
+
createdAt: 2025-05-20
|
|
3
|
+
updatedAt: 2025-06-29
|
|
4
|
+
title: Як налаштувати маршрутизацію на основі домену?
|
|
5
|
+
description: Дізнайтеся, як налаштувати маршрутизацію на основі домену.
|
|
6
|
+
keywords:
|
|
7
|
+
- домен
|
|
8
|
+
- маршрутизація
|
|
9
|
+
- intlayer
|
|
10
|
+
- конфігурація
|
|
11
|
+
- middleware
|
|
12
|
+
- react-router
|
|
13
|
+
- vue-router
|
|
14
|
+
- next.js
|
|
15
|
+
- vite
|
|
16
|
+
- фреймворк
|
|
17
|
+
slugs:
|
|
18
|
+
- frequent-questions
|
|
19
|
+
- domain-routing
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
# Як налаштувати **маршрутизацію на основі домену** в Intlayer замість шляхів `/[locale]/`?
|
|
23
|
+
|
|
24
|
+
## Коротка відповідь
|
|
25
|
+
|
|
26
|
+
Маршрутизація на основі домену простіша за маршрутизацію через шляхи (`example.com/[locale]/`), оскільки ви можете пропустити всю конфігурацію middleware та маршрутизації. Просто розгорніть ваш додаток на кожному мовному домені та встановіть по одній змінній оточення для кожного домену.
|
|
27
|
+
|
|
28
|
+
## Покроково
|
|
29
|
+
|
|
30
|
+
1. **Розгорніть додаток окремо для кожного домену** (`example.com`, `exemple.fr`, `ejemplo.es`, …).
|
|
31
|
+
2. Для кожного розгортання встановіть `LOCALE` (та звичайні змінні оточення Intlayer) у локаль, яку має обслуговувати цей домен.
|
|
32
|
+
3. Посилайтеся на цю змінну як `defaultLocale` у вашому `intlayer.config.[ts|js]`.
|
|
33
|
+
|
|
34
|
+
```ts
|
|
35
|
+
import { Locales, type IntlayerConfig } from "intlayer";
|
|
36
|
+
|
|
37
|
+
const config: IntlayerConfig = {
|
|
38
|
+
internationalization: {
|
|
39
|
+
locales: [Locales.ENGLISH, Locales.FRENCH, Locales.SPANISH],
|
|
40
|
+
defaultLocale: process.env.LOCALE, // 👈 домен визначає локаль
|
|
41
|
+
},
|
|
42
|
+
// ... решта вашої конфігурації
|
|
43
|
+
};
|
|
44
|
+
|
|
45
|
+
export default config;
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
Ось і все — те саме працює для **Next.js**, **Vite + React**, **Vite + Vue** тощо.
|
|
49
|
+
|
|
50
|
+
## Що якщо всі домени вказують на **те саме** розгортання?
|
|
51
|
+
|
|
52
|
+
Якщо всі домени вказують на той самий бандл застосунку, вам потрібно визначати хост під час виконання та передавати локаль вручну через провайдер.
|
|
53
|
+
|
|
54
|
+
### Для Next.js
|
|
55
|
+
|
|
56
|
+
```tsx
|
|
57
|
+
// src/IntlayerProvider.tsx
|
|
58
|
+
import {
|
|
59
|
+
IntlayerClientProvider,
|
|
60
|
+
type IntlayerClientProviderProps,
|
|
61
|
+
} from "next-intlayer";
|
|
62
|
+
import { IntlayerServerProvider } from "next-intlayer/server";
|
|
63
|
+
import type { FC } from "react";
|
|
64
|
+
|
|
65
|
+
export const IntlayerProvider: FC<IntlayerClientProviderProps> = ({
|
|
66
|
+
children,
|
|
67
|
+
locale,
|
|
68
|
+
}) => {
|
|
69
|
+
const resolvedLocale = locale ?? getLocaleFromHostname();
|
|
70
|
+
return (
|
|
71
|
+
<IntlayerServerProvider locale={resolvedLocale}>
|
|
72
|
+
<IntlayerClientProvider locale={resolvedLocale}>
|
|
73
|
+
{children}
|
|
74
|
+
</IntlayerClientProvider>
|
|
75
|
+
</IntlayerServerProvider>
|
|
76
|
+
);
|
|
77
|
+
};
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
### Для Vue
|
|
81
|
+
|
|
82
|
+
```ts
|
|
83
|
+
import { createApp } from "vue";
|
|
84
|
+
import { installIntlayer } from "vue-intlayer";
|
|
85
|
+
import App from "./App.vue";
|
|
86
|
+
import { router } from "./routes";
|
|
87
|
+
|
|
88
|
+
const app = createApp(App);
|
|
89
|
+
app.use(router);
|
|
90
|
+
installIntlayer(app, getLocaleFromHostname());
|
|
91
|
+
app.mount("#app");
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
Замініть `getLocaleFromHostname()` своєю власною логікою визначення локалі.
|
|
95
|
+
|
|
96
|
+
## Оновіть ваш перемикач локалі
|
|
97
|
+
|
|
98
|
+
Коли використовується маршрутизація на основі доменів, зміна мови означає перехід на інший домен:
|
|
99
|
+
|
|
100
|
+
```ts
|
|
101
|
+
const { locale } = useLocale();
|
|
102
|
+
|
|
103
|
+
function changeLanguage(target: Locale) {
|
|
104
|
+
window.location.href = domainForLocale[target];
|
|
105
|
+
}
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
## Переваги маршрутизації на основі доменів
|
|
109
|
+
|
|
110
|
+
1. **Простіша конфігурація**: Немає потреби налаштовувати `intlayerProxy`, `generateStaticParams`, `react-router` або `vue-router`
|
|
111
|
+
2. **Краще SEO**: Кожна мова має власний домен
|
|
112
|
+
3. **Чистіші URL-адреси**: Немає префікса локалі в шляху
|
|
113
|
+
4. **Простіше обслуговування**: Розгортання для кожної мови незалежне
|