@intlayer/docs 6.1.6-canary.0 → 7.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/next-i18next_vs_next-intl_vs_intlayer.md +14 -0
- package/blog/en/{intlayer_with_next-i18next.mdx → _intlayer_with_next-i18next.md} +69 -72
- package/blog/en/{intlayer_with_next-intl.mdx → _intlayer_with_next-intl.md} +52 -56
- package/blog/en/next-i18next_vs_next-intl_vs_intlayer.md +85 -80
- package/dist/cjs/_virtual/rolldown_runtime.cjs +25 -0
- package/dist/cjs/blog.cjs +20 -45
- package/dist/cjs/blog.cjs.map +1 -1
- package/dist/cjs/common.cjs +60 -136
- package/dist/cjs/common.cjs.map +1 -1
- package/dist/cjs/doc.cjs +20 -45
- package/dist/cjs/doc.cjs.map +1 -1
- package/dist/cjs/frequentQuestions.cjs +20 -45
- package/dist/cjs/frequentQuestions.cjs.map +1 -1
- package/dist/cjs/generated/blog.entry.cjs +438 -407
- package/dist/cjs/generated/blog.entry.cjs.map +1 -1
- package/dist/cjs/generated/docs.entry.cjs +1407 -1118
- package/dist/cjs/generated/docs.entry.cjs.map +1 -1
- package/dist/cjs/generated/frequentQuestions.entry.cjs +286 -254
- package/dist/cjs/generated/frequentQuestions.entry.cjs.map +1 -1
- package/dist/cjs/generated/legal.entry.cjs +58 -78
- package/dist/cjs/generated/legal.entry.cjs.map +1 -1
- package/dist/cjs/index.cjs +33 -29
- package/dist/cjs/legal.cjs +20 -45
- package/dist/cjs/legal.cjs.map +1 -1
- package/dist/esm/blog.mjs +7 -17
- package/dist/esm/blog.mjs.map +1 -1
- package/dist/esm/common.mjs +45 -102
- package/dist/esm/common.mjs.map +1 -1
- package/dist/esm/doc.mjs +7 -17
- package/dist/esm/doc.mjs.map +1 -1
- package/dist/esm/frequentQuestions.mjs +7 -17
- package/dist/esm/frequentQuestions.mjs.map +1 -1
- package/dist/esm/generated/blog.entry.mjs +433 -382
- package/dist/esm/generated/blog.entry.mjs.map +1 -1
- package/dist/esm/generated/docs.entry.mjs +1402 -1093
- package/dist/esm/generated/docs.entry.mjs.map +1 -1
- package/dist/esm/generated/frequentQuestions.entry.mjs +281 -229
- package/dist/esm/generated/frequentQuestions.entry.mjs.map +1 -1
- package/dist/esm/generated/legal.entry.mjs +53 -53
- package/dist/esm/generated/legal.entry.mjs.map +1 -1
- package/dist/esm/index.mjs +6 -5
- package/dist/esm/legal.mjs +7 -17
- package/dist/esm/legal.mjs.map +1 -1
- package/dist/types/blog.d.ts +17 -12
- package/dist/types/blog.d.ts.map +1 -1
- package/dist/types/common.d.ts +30 -25
- package/dist/types/common.d.ts.map +1 -1
- package/dist/types/doc.d.ts +17 -12
- package/dist/types/doc.d.ts.map +1 -1
- package/dist/types/frequentQuestions.d.ts +17 -12
- package/dist/types/frequentQuestions.d.ts.map +1 -1
- package/dist/types/generated/blog.entry.d.ts +28 -24
- package/dist/types/generated/blog.entry.d.ts.map +1 -1
- package/dist/types/generated/docs.entry.d.ts +79 -69
- package/dist/types/generated/docs.entry.d.ts.map +1 -1
- package/dist/types/generated/frequentQuestions.entry.d.ts +20 -15
- package/dist/types/generated/frequentQuestions.entry.d.ts.map +1 -1
- package/dist/types/generated/legal.entry.d.ts +8 -4
- package/dist/types/generated/legal.entry.d.ts.map +1 -1
- package/dist/types/index.d.ts +5 -5
- package/dist/types/legal.d.ts +17 -12
- package/dist/types/legal.d.ts.map +1 -1
- package/docs/ar/CI_CD.md +4 -6
- package/docs/ar/autoFill.md +10 -8
- package/docs/ar/configuration.md +16 -10
- package/docs/ar/dictionary/content_file.md +7 -7
- package/docs/ar/dictionary/enumeration.md +4 -4
- package/docs/ar/dictionary/file.md +4 -4
- package/docs/ar/dictionary/function_fetching.md +4 -4
- package/docs/ar/dictionary/gender.md +4 -6
- package/docs/ar/dictionary/insertion.md +4 -4
- package/docs/ar/dictionary/translation.md +4 -4
- package/docs/ar/formatters.md +19 -33
- package/docs/ar/how_works_intlayer.md +5 -5
- package/docs/ar/index.md +4 -4
- package/docs/ar/interest_of_intlayer.md +7 -7
- package/docs/ar/intlayer_CMS.md +10 -8
- package/docs/ar/intlayer_cli.md +7 -7
- package/docs/ar/intlayer_visual_editor.md +5 -5
- package/docs/ar/intlayer_with_angular.md +8 -8
- package/docs/ar/intlayer_with_astro.md +244 -0
- package/docs/ar/intlayer_with_create_react_app.md +9 -8
- package/docs/ar/intlayer_with_express.md +8 -8
- package/docs/ar/intlayer_with_lynx+react.md +6 -6
- package/docs/ar/intlayer_with_nestjs.md +8 -10
- package/docs/ar/intlayer_with_nextjs_14.md +4 -4
- package/docs/ar/intlayer_with_nextjs_15.md +9 -8
- package/docs/ar/intlayer_with_nextjs_page_router.md +8 -8
- package/docs/ar/intlayer_with_nuxt.md +8 -8
- package/docs/ar/intlayer_with_react_native+expo.md +17 -26
- package/docs/ar/intlayer_with_react_router_v7.md +199 -245
- package/docs/ar/intlayer_with_tanstack.md +203 -279
- package/docs/ar/intlayer_with_vite+preact.md +15 -15
- package/docs/ar/intlayer_with_vite+react.md +14 -14
- package/docs/ar/intlayer_with_vite+solid.md +6 -6
- package/docs/ar/intlayer_with_vite+svelte.md +6 -6
- package/docs/ar/intlayer_with_vite+vue.md +15 -15
- package/docs/ar/introduction.md +4 -4
- package/docs/ar/locale_mapper.md +4 -6
- package/docs/ar/mcp_server.md +13 -9
- package/docs/ar/packages/express-intlayer/t.md +4 -4
- package/docs/ar/packages/intlayer/getConfiguration.md +4 -4
- package/docs/ar/packages/intlayer/getEnumeration.md +4 -4
- package/docs/ar/packages/intlayer/getHTMLTextDir.md +4 -4
- package/docs/ar/packages/intlayer/getLocaleLang.md +4 -4
- package/docs/ar/packages/intlayer/getLocaleName.md +4 -4
- package/docs/ar/packages/intlayer/getLocalizedUrl.md +4 -4
- package/docs/ar/packages/intlayer/getMultilingualUrls.md +4 -4
- package/docs/ar/packages/intlayer/getTranslation.md +4 -4
- package/docs/ar/packages/intlayer/getTranslationContent.md +4 -4
- package/docs/ar/packages/next-intlayer/t.md +4 -4
- package/docs/ar/packages/next-intlayer/useDictionary.md +4 -4
- package/docs/ar/packages/next-intlayer/useIntlayer.md +4 -4
- package/docs/ar/packages/next-intlayer/useLocale.md +4 -4
- package/docs/ar/packages/react-intlayer/t.md +4 -4
- package/docs/ar/packages/react-intlayer/useDictionary.md +4 -4
- package/docs/ar/packages/react-intlayer/useLocale.md +4 -4
- package/docs/ar/per_locale_file.md +4 -4
- package/docs/ar/roadmap.md +7 -5
- package/docs/ar/testing.md +4 -7
- package/docs/ar/vs_code_extension.md +13 -9
- package/docs/de/CI_CD.md +4 -6
- package/docs/de/autoFill.md +10 -8
- package/docs/de/configuration.md +16 -10
- package/docs/de/dictionary/content_file.md +7 -7
- package/docs/de/dictionary/enumeration.md +4 -4
- package/docs/de/dictionary/file.md +4 -4
- package/docs/de/dictionary/function_fetching.md +4 -4
- package/docs/de/dictionary/gender.md +4 -6
- package/docs/de/dictionary/insertion.md +4 -4
- package/docs/de/dictionary/translation.md +4 -4
- package/docs/de/formatters.md +25 -57
- package/docs/de/how_works_intlayer.md +5 -7
- package/docs/de/index.md +4 -4
- package/docs/de/interest_of_intlayer.md +7 -7
- package/docs/de/intlayer_CMS.md +10 -8
- package/docs/de/intlayer_cli.md +7 -7
- package/docs/de/intlayer_visual_editor.md +5 -6
- package/docs/de/intlayer_with_angular.md +8 -8
- package/docs/de/intlayer_with_astro.md +244 -0
- package/docs/de/intlayer_with_create_react_app.md +4 -4
- package/docs/de/intlayer_with_express.md +8 -8
- package/docs/de/intlayer_with_lynx+react.md +6 -6
- package/docs/de/intlayer_with_nestjs.md +8 -10
- package/docs/de/intlayer_with_nextjs_14.md +4 -4
- package/docs/de/intlayer_with_nextjs_15.md +9 -8
- package/docs/de/intlayer_with_nextjs_page_router.md +8 -8
- package/docs/de/intlayer_with_nuxt.md +8 -8
- package/docs/de/intlayer_with_react_native+expo.md +17 -26
- package/docs/de/intlayer_with_react_router_v7.md +197 -246
- package/docs/de/intlayer_with_tanstack.md +198 -272
- package/docs/de/intlayer_with_vite+preact.md +15 -15
- package/docs/de/intlayer_with_vite+react.md +16 -15
- package/docs/de/intlayer_with_vite+solid.md +6 -6
- package/docs/de/intlayer_with_vite+svelte.md +6 -6
- package/docs/de/intlayer_with_vite+vue.md +17 -17
- package/docs/de/introduction.md +4 -4
- package/docs/de/locale_mapper.md +4 -6
- package/docs/de/mcp_server.md +13 -9
- package/docs/de/packages/express-intlayer/t.md +4 -4
- package/docs/de/packages/intlayer/getConfiguration.md +4 -4
- package/docs/de/packages/intlayer/getEnumeration.md +4 -4
- package/docs/de/packages/intlayer/getHTMLTextDir.md +4 -4
- package/docs/de/packages/intlayer/getLocaleLang.md +4 -4
- package/docs/de/packages/intlayer/getLocaleName.md +4 -4
- package/docs/de/packages/intlayer/getLocalizedUrl.md +4 -4
- package/docs/de/packages/intlayer/getMultilingualUrls.md +4 -4
- package/docs/de/packages/intlayer/getPathWithoutLocale.md +4 -4
- package/docs/de/packages/intlayer/getTranslation.md +4 -4
- package/docs/de/packages/intlayer/getTranslationContent.md +4 -4
- package/docs/de/packages/next-intlayer/t.md +4 -4
- package/docs/de/packages/next-intlayer/useDictionary.md +4 -4
- package/docs/de/packages/next-intlayer/useIntlayer.md +4 -4
- package/docs/de/packages/next-intlayer/useLocale.md +4 -4
- package/docs/de/packages/react-intlayer/t.md +4 -4
- package/docs/de/packages/react-intlayer/useDictionary.md +4 -4
- package/docs/de/packages/react-intlayer/useI18n.md +4 -4
- package/docs/de/packages/react-intlayer/useIntlayer.md +4 -4
- package/docs/de/packages/react-intlayer/useLocale.md +4 -4
- package/docs/de/per_locale_file.md +4 -4
- package/docs/de/roadmap.md +7 -5
- package/docs/de/testing.md +4 -7
- package/docs/de/vs_code_extension.md +13 -9
- package/docs/en/CI_CD.md +4 -6
- package/docs/en/autoFill.md +75 -28
- package/docs/en/configuration.md +214 -56
- package/docs/en/dictionary/condition.md +4 -6
- package/docs/en/dictionary/content_file.md +25 -17
- package/docs/en/dictionary/enumeration.md +4 -6
- package/docs/en/dictionary/file.md +16 -8
- package/docs/en/dictionary/function_fetching.md +4 -6
- package/docs/en/dictionary/gender.md +4 -6
- package/docs/en/dictionary/insertion.md +4 -6
- package/docs/en/dictionary/markdown.md +4 -6
- package/docs/en/dictionary/nesting.md +4 -6
- package/docs/en/dictionary/translation.md +4 -6
- package/docs/en/formatters.md +23 -50
- package/docs/en/how_works_intlayer.md +6 -8
- package/docs/en/index.md +5 -7
- package/docs/en/interest_of_intlayer.md +7 -7
- package/docs/en/intlayer_CMS.md +12 -12
- package/docs/en/intlayer_cli.md +97 -14
- package/docs/en/intlayer_visual_editor.md +14 -10
- package/docs/en/intlayer_with_angular.md +10 -12
- package/docs/en/intlayer_with_astro.md +244 -0
- package/docs/en/intlayer_with_create_react_app.md +10 -12
- package/docs/en/intlayer_with_express.md +9 -11
- package/docs/en/intlayer_with_lynx+react.md +7 -9
- package/docs/en/intlayer_with_nestjs.md +8 -10
- package/docs/en/intlayer_with_next-i18next.md +627 -0
- package/docs/en/intlayer_with_next-intl.md +446 -0
- package/docs/en/intlayer_with_nextjs_14.md +66 -31
- package/docs/en/intlayer_with_nextjs_15.md +81 -35
- package/docs/en/intlayer_with_nextjs_16.md +1586 -0
- package/docs/en/intlayer_with_nextjs_page_router.md +23 -15
- package/docs/en/intlayer_with_nuxt.md +10 -12
- package/docs/en/intlayer_with_react_native+expo.md +49 -27
- package/docs/en/intlayer_with_react_router_v7.md +169 -216
- package/docs/en/intlayer_with_tanstack.md +174 -249
- package/docs/en/intlayer_with_vite+preact.md +18 -20
- package/docs/en/intlayer_with_vite+react.md +68 -317
- package/docs/en/intlayer_with_vite+solid.md +8 -10
- package/docs/en/intlayer_with_vite+svelte.md +8 -10
- package/docs/en/intlayer_with_vite+vue.md +18 -20
- package/docs/en/introduction.md +5 -7
- package/docs/en/locale_mapper.md +4 -6
- package/docs/en/mcp_server.md +13 -9
- package/docs/en/packages/express-intlayer/t.md +4 -6
- package/docs/en/packages/intlayer/getConfiguration.md +4 -6
- package/docs/en/packages/intlayer/getEnumeration.md +4 -6
- package/docs/en/packages/intlayer/getHTMLTextDir.md +4 -6
- package/docs/en/packages/intlayer/getLocaleLang.md +4 -6
- package/docs/en/packages/intlayer/getLocaleName.md +4 -6
- package/docs/en/packages/intlayer/getLocalizedUrl.md +4 -6
- package/docs/en/packages/intlayer/getMultilingualUrls.md +4 -6
- package/docs/en/packages/intlayer/getPathWithoutLocale.md +4 -6
- package/docs/en/packages/intlayer/getTranslation.md +4 -6
- package/docs/en/packages/intlayer/getTranslationContent.md +4 -6
- package/docs/en/packages/next-intlayer/t.md +4 -6
- package/docs/en/packages/next-intlayer/useDictionary.md +5 -7
- package/docs/en/packages/next-intlayer/useIntlayer.md +5 -7
- package/docs/en/packages/next-intlayer/useLocale.md +41 -8
- package/docs/en/packages/react-intlayer/t.md +4 -6
- package/docs/en/packages/react-intlayer/useDictionary.md +5 -7
- package/docs/en/packages/react-intlayer/useI18n.md +5 -5
- package/docs/en/packages/react-intlayer/useIntlayer.md +5 -7
- package/docs/en/packages/react-intlayer/useLocale.md +4 -6
- package/docs/en/per_locale_file.md +4 -6
- package/docs/en/plugins/sync-json.md +244 -0
- package/docs/en/releases/v6.md +7 -0
- package/docs/en/releases/v7.md +486 -0
- package/docs/en/roadmap.md +11 -9
- package/docs/en/testing.md +13 -11
- package/docs/en/vs_code_extension.md +13 -9
- package/docs/en-GB/CI_CD.md +4 -6
- package/docs/en-GB/autoFill.md +10 -8
- package/docs/en-GB/configuration.md +16 -10
- package/docs/en-GB/dictionary/condition.md +4 -4
- package/docs/en-GB/dictionary/content_file.md +7 -7
- package/docs/en-GB/dictionary/enumeration.md +4 -4
- package/docs/en-GB/dictionary/file.md +4 -4
- package/docs/en-GB/dictionary/gender.md +4 -6
- package/docs/en-GB/dictionary/insertion.md +4 -4
- package/docs/en-GB/dictionary/markdown.md +4 -4
- package/docs/en-GB/dictionary/nesting.md +4 -4
- package/docs/en-GB/dictionary/translation.md +4 -4
- package/docs/en-GB/formatters.md +19 -33
- package/docs/en-GB/how_works_intlayer.md +5 -5
- package/docs/en-GB/index.md +4 -4
- package/docs/en-GB/interest_of_intlayer.md +7 -7
- package/docs/en-GB/intlayer_CMS.md +15 -13
- package/docs/en-GB/intlayer_cli.md +7 -7
- package/docs/en-GB/intlayer_visual_editor.md +5 -6
- package/docs/en-GB/intlayer_with_angular.md +8 -8
- package/docs/en-GB/intlayer_with_astro.md +244 -0
- package/docs/en-GB/intlayer_with_create_react_app.md +11 -10
- package/docs/en-GB/intlayer_with_express.md +8 -8
- package/docs/en-GB/intlayer_with_lynx+react.md +5 -5
- package/docs/en-GB/intlayer_with_nestjs.md +7 -9
- package/docs/en-GB/intlayer_with_nextjs_14.md +10 -10
- package/docs/en-GB/intlayer_with_nextjs_15.md +8 -7
- package/docs/en-GB/intlayer_with_nextjs_page_router.md +7 -7
- package/docs/en-GB/intlayer_with_nuxt.md +7 -7
- package/docs/en-GB/intlayer_with_react_native+expo.md +16 -25
- package/docs/en-GB/intlayer_with_react_router_v7.md +175 -224
- package/docs/en-GB/intlayer_with_tanstack.md +181 -255
- package/docs/en-GB/intlayer_with_vite+preact.md +14 -14
- package/docs/en-GB/intlayer_with_vite+react.md +15 -14
- package/docs/en-GB/intlayer_with_vite+solid.md +5 -5
- package/docs/en-GB/intlayer_with_vite+svelte.md +5 -5
- package/docs/en-GB/intlayer_with_vite+vue.md +16 -16
- package/docs/en-GB/introduction.md +4 -4
- package/docs/en-GB/locale_mapper.md +4 -6
- package/docs/en-GB/mcp_server.md +13 -9
- package/docs/en-GB/packages/express-intlayer/t.md +4 -4
- package/docs/en-GB/packages/intlayer/getConfiguration.md +4 -4
- package/docs/en-GB/packages/intlayer/getEnumeration.md +4 -4
- package/docs/en-GB/packages/intlayer/getHTMLTextDir.md +4 -4
- package/docs/en-GB/packages/intlayer/getLocaleLang.md +4 -4
- package/docs/en-GB/packages/intlayer/getLocaleName.md +4 -4
- package/docs/en-GB/packages/intlayer/getLocalizedUrl.md +4 -4
- package/docs/en-GB/packages/intlayer/getMultilingualUrls.md +4 -4
- package/docs/en-GB/packages/intlayer/getPathWithoutLocale.md +4 -4
- package/docs/en-GB/packages/intlayer/getTranslation.md +4 -4
- package/docs/en-GB/packages/intlayer/getTranslationContent.md +4 -4
- package/docs/en-GB/packages/next-intlayer/t.md +4 -4
- package/docs/en-GB/packages/next-intlayer/useDictionary.md +4 -4
- package/docs/en-GB/packages/next-intlayer/useIntlayer.md +5 -5
- package/docs/en-GB/packages/next-intlayer/useLocale.md +4 -4
- package/docs/en-GB/packages/react-intlayer/t.md +4 -4
- package/docs/en-GB/packages/react-intlayer/useDictionary.md +4 -4
- package/docs/en-GB/packages/react-intlayer/useI18n.md +4 -4
- package/docs/en-GB/packages/react-intlayer/useIntlayer.md +5 -5
- package/docs/en-GB/packages/react-intlayer/useLocale.md +4 -4
- package/docs/en-GB/per_locale_file.md +4 -4
- package/docs/en-GB/roadmap.md +7 -5
- package/docs/en-GB/testing.md +4 -7
- package/docs/en-GB/vs_code_extension.md +13 -9
- package/docs/es/CI_CD.md +4 -6
- package/docs/es/autoFill.md +10 -8
- package/docs/es/configuration.md +16 -10
- package/docs/es/dictionary/content_file.md +7 -7
- package/docs/es/dictionary/enumeration.md +4 -4
- package/docs/es/dictionary/file.md +4 -4
- package/docs/es/dictionary/function_fetching.md +4 -4
- package/docs/es/dictionary/gender.md +4 -6
- package/docs/es/dictionary/insertion.md +4 -4
- package/docs/es/dictionary/translation.md +4 -4
- package/docs/es/formatters.md +25 -57
- package/docs/es/how_works_intlayer.md +5 -5
- package/docs/es/index.md +4 -4
- package/docs/es/interest_of_intlayer.md +7 -7
- package/docs/es/intlayer_CMS.md +10 -8
- package/docs/es/intlayer_cli.md +7 -7
- package/docs/es/intlayer_visual_editor.md +5 -7
- package/docs/es/intlayer_with_angular.md +8 -8
- package/docs/es/intlayer_with_astro.md +244 -0
- package/docs/es/intlayer_with_create_react_app.md +9 -8
- package/docs/es/intlayer_with_express.md +8 -8
- package/docs/es/intlayer_with_lynx+react.md +6 -6
- package/docs/es/intlayer_with_nestjs.md +6 -8
- package/docs/es/intlayer_with_nextjs_14.md +8 -8
- package/docs/es/intlayer_with_nextjs_15.md +9 -8
- package/docs/es/intlayer_with_nextjs_page_router.md +6 -6
- package/docs/es/intlayer_with_nuxt.md +6 -6
- package/docs/es/intlayer_with_react_native+expo.md +17 -26
- package/docs/es/intlayer_with_react_router_v7.md +191 -235
- package/docs/es/intlayer_with_tanstack.md +208 -280
- package/docs/es/intlayer_with_vite+preact.md +13 -13
- package/docs/es/intlayer_with_vite+react.md +14 -13
- package/docs/es/intlayer_with_vite+solid.md +6 -6
- package/docs/es/intlayer_with_vite+svelte.md +6 -6
- package/docs/es/intlayer_with_vite+vue.md +15 -15
- package/docs/es/introduction.md +4 -4
- package/docs/es/locale_mapper.md +4 -6
- package/docs/es/mcp_server.md +13 -9
- package/docs/es/packages/express-intlayer/t.md +4 -4
- package/docs/es/packages/intlayer/getConfiguration.md +4 -4
- package/docs/es/packages/intlayer/getEnumeration.md +4 -4
- package/docs/es/packages/intlayer/getHTMLTextDir.md +4 -4
- package/docs/es/packages/intlayer/getLocaleLang.md +4 -4
- package/docs/es/packages/intlayer/getLocaleName.md +4 -4
- package/docs/es/packages/intlayer/getLocalizedUrl.md +4 -4
- package/docs/es/packages/intlayer/getMultilingualUrls.md +4 -4
- package/docs/es/packages/intlayer/getPathWithoutLocale.md +4 -4
- package/docs/es/packages/intlayer/getTranslation.md +4 -4
- package/docs/es/packages/intlayer/getTranslationContent.md +4 -4
- package/docs/es/packages/next-intlayer/index.md +4 -4
- package/docs/es/packages/next-intlayer/t.md +4 -4
- package/docs/es/packages/next-intlayer/useDictionary.md +4 -4
- package/docs/es/packages/next-intlayer/useIntlayer.md +4 -4
- package/docs/es/packages/next-intlayer/useLocale.md +4 -4
- package/docs/es/packages/react-intlayer/index.md +4 -4
- package/docs/es/packages/react-intlayer/t.md +4 -4
- package/docs/es/packages/react-intlayer/useDictionary.md +4 -4
- package/docs/es/packages/react-intlayer/useI18n.md +4 -4
- package/docs/es/packages/react-intlayer/useIntlayer.md +4 -4
- package/docs/es/packages/react-intlayer/useLocale.md +4 -4
- package/docs/es/per_locale_file.md +4 -4
- package/docs/es/roadmap.md +7 -5
- package/docs/es/testing.md +4 -7
- package/docs/es/vs_code_extension.md +13 -9
- package/docs/fr/CI_CD.md +4 -4
- package/docs/fr/autoFill.md +10 -8
- package/docs/fr/configuration.md +19 -22
- package/docs/fr/dictionary/content_file.md +7 -7
- package/docs/fr/dictionary/enumeration.md +4 -4
- package/docs/fr/dictionary/file.md +4 -4
- package/docs/fr/dictionary/function_fetching.md +4 -4
- package/docs/fr/dictionary/gender.md +4 -6
- package/docs/fr/dictionary/insertion.md +4 -4
- package/docs/fr/dictionary/translation.md +4 -4
- package/docs/fr/formatters.md +25 -57
- package/docs/fr/how_works_intlayer.md +5 -5
- package/docs/fr/index.md +4 -4
- package/docs/fr/interest_of_intlayer.md +7 -7
- package/docs/fr/intlayer_CMS.md +10 -8
- package/docs/fr/intlayer_cli.md +7 -7
- package/docs/fr/intlayer_visual_editor.md +5 -6
- package/docs/fr/intlayer_with_angular.md +8 -8
- package/docs/fr/intlayer_with_astro.md +244 -0
- package/docs/fr/intlayer_with_create_react_app.md +9 -8
- package/docs/fr/intlayer_with_express.md +8 -8
- package/docs/fr/intlayer_with_lynx+react.md +6 -6
- package/docs/fr/intlayer_with_nestjs.md +8 -10
- package/docs/fr/intlayer_with_nextjs_14.md +4 -4
- package/docs/fr/intlayer_with_nextjs_15.md +7 -6
- package/docs/fr/intlayer_with_nextjs_page_router.md +6 -6
- package/docs/fr/intlayer_with_nuxt.md +6 -6
- package/docs/fr/intlayer_with_react_native+expo.md +17 -26
- package/docs/fr/intlayer_with_react_router_v7.md +192 -252
- package/docs/fr/intlayer_with_tanstack.md +197 -272
- package/docs/fr/intlayer_with_vite+preact.md +13 -13
- package/docs/fr/intlayer_with_vite+react.md +13 -13
- package/docs/fr/intlayer_with_vite+solid.md +6 -6
- package/docs/fr/intlayer_with_vite+svelte.md +6 -6
- package/docs/fr/intlayer_with_vite+vue.md +15 -15
- package/docs/fr/introduction.md +4 -4
- package/docs/fr/locale_mapper.md +4 -6
- package/docs/fr/mcp_server.md +13 -9
- package/docs/fr/packages/express-intlayer/t.md +4 -4
- package/docs/fr/packages/intlayer/getConfiguration.md +4 -4
- package/docs/fr/packages/intlayer/getEnumeration.md +4 -4
- package/docs/fr/packages/intlayer/getHTMLTextDir.md +4 -4
- package/docs/fr/packages/intlayer/getLocaleLang.md +4 -4
- package/docs/fr/packages/intlayer/getLocaleName.md +4 -4
- package/docs/fr/packages/intlayer/getLocalizedUrl.md +4 -4
- package/docs/fr/packages/intlayer/getMultilingualUrls.md +4 -4
- package/docs/fr/packages/intlayer/getPathWithoutLocale.md +4 -4
- package/docs/fr/packages/intlayer/getTranslation.md +4 -4
- package/docs/fr/packages/intlayer/getTranslationContent.md +4 -4
- package/docs/fr/packages/next-intlayer/t.md +4 -4
- package/docs/fr/packages/next-intlayer/useDictionary.md +4 -4
- package/docs/fr/packages/next-intlayer/useIntlayer.md +4 -4
- package/docs/fr/packages/next-intlayer/useLocale.md +4 -4
- package/docs/fr/packages/react-intlayer/index.md +4 -4
- package/docs/fr/packages/react-intlayer/t.md +4 -4
- package/docs/fr/packages/react-intlayer/useDictionary.md +4 -4
- package/docs/fr/packages/react-intlayer/useI18n.md +4 -4
- package/docs/fr/packages/react-intlayer/useIntlayer.md +4 -4
- package/docs/fr/packages/react-intlayer/useLocale.md +4 -4
- package/docs/fr/per_locale_file.md +4 -4
- package/docs/fr/roadmap.md +7 -5
- package/docs/fr/testing.md +4 -7
- package/docs/fr/vs_code_extension.md +13 -9
- package/docs/hi/CI_CD.md +4 -6
- package/docs/hi/autoFill.md +10 -8
- package/docs/hi/configuration.md +16 -10
- package/docs/hi/dictionary/content_file.md +7 -7
- package/docs/hi/dictionary/enumeration.md +4 -4
- package/docs/hi/dictionary/file.md +4 -4
- package/docs/hi/dictionary/function_fetching.md +4 -4
- package/docs/hi/dictionary/gender.md +4 -6
- package/docs/hi/dictionary/insertion.md +4 -4
- package/docs/hi/dictionary/translation.md +4 -4
- package/docs/hi/formatters.md +19 -33
- package/docs/hi/how_works_intlayer.md +5 -5
- package/docs/hi/index.md +4 -4
- package/docs/hi/interest_of_intlayer.md +7 -7
- package/docs/hi/intlayer_CMS.md +10 -8
- package/docs/hi/intlayer_cli.md +8 -11
- package/docs/hi/intlayer_visual_editor.md +5 -6
- package/docs/hi/intlayer_with_angular.md +8 -8
- package/docs/hi/intlayer_with_astro.md +244 -0
- package/docs/hi/intlayer_with_create_react_app.md +4 -4
- package/docs/hi/intlayer_with_express.md +8 -8
- package/docs/hi/intlayer_with_lynx+react.md +6 -6
- package/docs/hi/intlayer_with_nestjs.md +8 -10
- package/docs/hi/intlayer_with_nextjs_14.md +4 -4
- package/docs/hi/intlayer_with_nextjs_15.md +9 -8
- package/docs/hi/intlayer_with_nextjs_page_router.md +8 -8
- package/docs/hi/intlayer_with_nuxt.md +8 -8
- package/docs/hi/intlayer_with_react_native+expo.md +17 -26
- package/docs/hi/intlayer_with_react_router_v7.md +204 -248
- package/docs/hi/intlayer_with_tanstack.md +215 -290
- package/docs/hi/intlayer_with_vite+preact.md +15 -15
- package/docs/hi/intlayer_with_vite+react.md +16 -15
- package/docs/hi/intlayer_with_vite+solid.md +7 -7
- package/docs/hi/intlayer_with_vite+svelte.md +6 -6
- package/docs/hi/intlayer_with_vite+vue.md +17 -17
- package/docs/hi/introduction.md +4 -4
- package/docs/hi/locale_mapper.md +4 -6
- package/docs/hi/mcp_server.md +13 -9
- package/docs/hi/packages/express-intlayer/t.md +4 -4
- package/docs/hi/packages/intlayer/getConfiguration.md +4 -4
- package/docs/hi/packages/intlayer/getEnumeration.md +4 -4
- package/docs/hi/packages/intlayer/getHTMLTextDir.md +4 -4
- package/docs/hi/packages/intlayer/getLocaleLang.md +4 -4
- package/docs/hi/packages/intlayer/getLocaleName.md +4 -4
- package/docs/hi/packages/intlayer/getLocalizedUrl.md +4 -4
- package/docs/hi/packages/intlayer/getMultilingualUrls.md +4 -4
- package/docs/hi/packages/intlayer/getPathWithoutLocale.md +4 -4
- package/docs/hi/packages/intlayer/getTranslation.md +4 -4
- package/docs/hi/packages/intlayer/getTranslationContent.md +4 -4
- package/docs/hi/packages/intlayer/index.md +4 -4
- package/docs/hi/packages/next-intlayer/t.md +4 -4
- package/docs/hi/packages/next-intlayer/useDictionary.md +4 -4
- package/docs/hi/packages/next-intlayer/useIntlayer.md +4 -4
- package/docs/hi/packages/next-intlayer/useLocale.md +4 -4
- package/docs/hi/packages/react-intlayer/t.md +4 -4
- package/docs/hi/packages/react-intlayer/useDictionary.md +4 -4
- package/docs/hi/packages/react-intlayer/useIntlayer.md +4 -4
- package/docs/hi/packages/react-intlayer/useLocale.md +4 -4
- package/docs/hi/per_locale_file.md +4 -4
- package/docs/hi/roadmap.md +7 -5
- package/docs/hi/testing.md +4 -7
- package/docs/hi/vs_code_extension.md +13 -9
- package/docs/it/CI_CD.md +4 -6
- package/docs/it/autoFill.md +10 -8
- package/docs/it/configuration.md +16 -10
- package/docs/it/dictionary/content_file.md +7 -7
- package/docs/it/dictionary/enumeration.md +4 -4
- package/docs/it/dictionary/file.md +4 -4
- package/docs/it/dictionary/function_fetching.md +4 -4
- package/docs/it/dictionary/gender.md +4 -6
- package/docs/it/dictionary/insertion.md +4 -4
- package/docs/it/dictionary/translation.md +4 -4
- package/docs/it/formatters.md +19 -55
- package/docs/it/how_works_intlayer.md +5 -5
- package/docs/it/index.md +4 -4
- package/docs/it/interest_of_intlayer.md +7 -7
- package/docs/it/intlayer_CMS.md +10 -8
- package/docs/it/intlayer_cli.md +7 -7
- package/docs/it/intlayer_visual_editor.md +5 -6
- package/docs/it/intlayer_with_angular.md +8 -8
- package/docs/it/intlayer_with_astro.md +244 -0
- package/docs/it/intlayer_with_create_react_app.md +9 -8
- package/docs/it/intlayer_with_express.md +8 -8
- package/docs/it/intlayer_with_lynx+react.md +6 -6
- package/docs/it/intlayer_with_nestjs.md +8 -10
- package/docs/it/intlayer_with_nextjs_14.md +4 -4
- package/docs/it/intlayer_with_nextjs_15.md +9 -8
- package/docs/it/intlayer_with_nextjs_page_router.md +8 -8
- package/docs/it/intlayer_with_nuxt.md +8 -8
- package/docs/it/intlayer_with_react_native+expo.md +17 -27
- package/docs/it/intlayer_with_react_router_v7.md +198 -245
- package/docs/it/intlayer_with_tanstack.md +207 -271
- package/docs/it/intlayer_with_vite+preact.md +15 -15
- package/docs/it/intlayer_with_vite+react.md +20 -17
- package/docs/it/intlayer_with_vite+solid.md +6 -6
- package/docs/it/intlayer_with_vite+svelte.md +6 -6
- package/docs/it/intlayer_with_vite+vue.md +17 -17
- package/docs/it/introduction.md +4 -4
- package/docs/it/locale_mapper.md +4 -6
- package/docs/it/mcp_server.md +13 -9
- package/docs/it/packages/express-intlayer/t.md +4 -4
- package/docs/it/packages/intlayer/getConfiguration.md +4 -4
- package/docs/it/packages/intlayer/getEnumeration.md +4 -4
- package/docs/it/packages/intlayer/getHTMLTextDir.md +4 -4
- package/docs/it/packages/intlayer/getLocaleLang.md +4 -4
- package/docs/it/packages/intlayer/getLocaleName.md +4 -4
- package/docs/it/packages/intlayer/getLocalizedUrl.md +4 -4
- package/docs/it/packages/intlayer/getMultilingualUrls.md +4 -4
- package/docs/it/packages/intlayer/getPathWithoutLocale.md +4 -4
- package/docs/it/packages/intlayer/getTranslation.md +4 -4
- package/docs/it/packages/intlayer/getTranslationContent.md +4 -4
- package/docs/it/packages/next-intlayer/t.md +4 -4
- package/docs/it/packages/next-intlayer/useDictionary.md +4 -4
- package/docs/it/packages/next-intlayer/useIntlayer.md +4 -4
- package/docs/it/packages/next-intlayer/useLocale.md +4 -4
- package/docs/it/packages/react-intlayer/t.md +4 -4
- package/docs/it/packages/react-intlayer/useDictionary.md +4 -4
- package/docs/it/packages/react-intlayer/useI18n.md +4 -4
- package/docs/it/packages/react-intlayer/useIntlayer.md +4 -4
- package/docs/it/packages/react-intlayer/useLocale.md +4 -4
- package/docs/it/per_locale_file.md +4 -4
- package/docs/it/roadmap.md +7 -5
- package/docs/it/testing.md +4 -7
- package/docs/it/vs_code_extension.md +13 -9
- package/docs/ja/CI_CD.md +4 -6
- package/docs/ja/autoFill.md +10 -8
- package/docs/ja/configuration.md +19 -22
- package/docs/ja/dictionary/content_file.md +7 -7
- package/docs/ja/dictionary/enumeration.md +4 -4
- package/docs/ja/dictionary/file.md +5 -5
- package/docs/ja/dictionary/function_fetching.md +4 -4
- package/docs/ja/dictionary/gender.md +4 -6
- package/docs/ja/dictionary/insertion.md +4 -4
- package/docs/ja/dictionary/translation.md +4 -4
- package/docs/ja/formatters.md +25 -57
- package/docs/ja/how_works_intlayer.md +5 -5
- package/docs/ja/index.md +4 -4
- package/docs/ja/interest_of_intlayer.md +7 -7
- package/docs/ja/intlayer_CMS.md +10 -9
- package/docs/ja/intlayer_cli.md +7 -7
- package/docs/ja/intlayer_visual_editor.md +5 -6
- package/docs/ja/intlayer_with_angular.md +8 -8
- package/docs/ja/intlayer_with_astro.md +244 -0
- package/docs/ja/intlayer_with_create_react_app.md +9 -8
- package/docs/ja/intlayer_with_express.md +8 -8
- package/docs/ja/intlayer_with_lynx+react.md +6 -6
- package/docs/ja/intlayer_with_nestjs.md +8 -10
- package/docs/ja/intlayer_with_nextjs_14.md +8 -8
- package/docs/ja/intlayer_with_nextjs_15.md +9 -8
- package/docs/ja/intlayer_with_nextjs_page_router.md +8 -8
- package/docs/ja/intlayer_with_nuxt.md +8 -8
- package/docs/ja/intlayer_with_react_native+expo.md +24 -35
- package/docs/ja/intlayer_with_react_router_v7.md +207 -253
- package/docs/ja/intlayer_with_tanstack.md +220 -290
- package/docs/ja/intlayer_with_vite+preact.md +15 -15
- package/docs/ja/intlayer_with_vite+react.md +18 -17
- package/docs/ja/intlayer_with_vite+solid.md +6 -6
- package/docs/ja/intlayer_with_vite+svelte.md +6 -6
- package/docs/ja/intlayer_with_vite+vue.md +17 -17
- package/docs/ja/introduction.md +4 -4
- package/docs/ja/locale_mapper.md +4 -6
- package/docs/ja/mcp_server.md +13 -9
- package/docs/ja/packages/express-intlayer/t.md +4 -4
- package/docs/ja/packages/intlayer/getConfiguration.md +4 -4
- package/docs/ja/packages/intlayer/getEnumeration.md +4 -4
- package/docs/ja/packages/intlayer/getHTMLTextDir.md +4 -4
- package/docs/ja/packages/intlayer/getLocaleLang.md +4 -4
- package/docs/ja/packages/intlayer/getLocaleName.md +4 -4
- package/docs/ja/packages/intlayer/getLocalizedUrl.md +4 -4
- package/docs/ja/packages/intlayer/getMultilingualUrls.md +4 -4
- package/docs/ja/packages/intlayer/getPathWithoutLocale.md +4 -4
- package/docs/ja/packages/intlayer/getTranslation.md +4 -4
- package/docs/ja/packages/intlayer/getTranslationContent.md +4 -4
- package/docs/ja/packages/next-intlayer/t.md +4 -4
- package/docs/ja/packages/next-intlayer/useDictionary.md +4 -4
- package/docs/ja/packages/next-intlayer/useIntlayer.md +4 -4
- package/docs/ja/packages/next-intlayer/useLocale.md +4 -4
- package/docs/ja/packages/react-intlayer/t.md +4 -4
- package/docs/ja/packages/react-intlayer/useDictionary.md +4 -4
- package/docs/ja/packages/react-intlayer/useI18n.md +4 -4
- package/docs/ja/packages/react-intlayer/useIntlayer.md +4 -4
- package/docs/ja/packages/react-intlayer/useLocale.md +4 -4
- package/docs/ja/per_locale_file.md +4 -4
- package/docs/ja/roadmap.md +7 -5
- package/docs/ja/testing.md +4 -7
- package/docs/ja/vs_code_extension.md +13 -9
- package/docs/ko/CI_CD.md +4 -6
- package/docs/ko/autoFill.md +10 -8
- package/docs/ko/configuration.md +19 -22
- package/docs/ko/dictionary/content_file.md +7 -7
- package/docs/ko/dictionary/enumeration.md +4 -4
- package/docs/ko/dictionary/file.md +4 -4
- package/docs/ko/dictionary/function_fetching.md +4 -4
- package/docs/ko/dictionary/gender.md +4 -6
- package/docs/ko/dictionary/insertion.md +4 -4
- package/docs/ko/dictionary/translation.md +4 -4
- package/docs/ko/formatters.md +19 -33
- package/docs/ko/how_works_intlayer.md +5 -5
- package/docs/ko/index.md +4 -4
- package/docs/ko/interest_of_intlayer.md +7 -7
- package/docs/ko/intlayer_CMS.md +10 -8
- package/docs/ko/intlayer_cli.md +7 -7
- package/docs/ko/intlayer_visual_editor.md +5 -6
- package/docs/ko/intlayer_with_angular.md +8 -8
- package/docs/ko/intlayer_with_astro.md +244 -0
- package/docs/ko/intlayer_with_create_react_app.md +9 -8
- package/docs/ko/intlayer_with_express.md +8 -8
- package/docs/ko/intlayer_with_lynx+react.md +6 -10
- package/docs/ko/intlayer_with_nestjs.md +8 -10
- package/docs/ko/intlayer_with_nextjs_14.md +8 -8
- package/docs/ko/intlayer_with_nextjs_15.md +9 -8
- package/docs/ko/intlayer_with_nextjs_page_router.md +8 -8
- package/docs/ko/intlayer_with_nuxt.md +8 -8
- package/docs/ko/intlayer_with_react_native+expo.md +25 -34
- package/docs/ko/intlayer_with_react_router_v7.md +195 -249
- package/docs/ko/intlayer_with_tanstack.md +202 -274
- package/docs/ko/intlayer_with_vite+preact.md +15 -15
- package/docs/ko/intlayer_with_vite+react.md +17 -16
- package/docs/ko/intlayer_with_vite+solid.md +6 -6
- package/docs/ko/intlayer_with_vite+svelte.md +6 -6
- package/docs/ko/intlayer_with_vite+vue.md +17 -17
- package/docs/ko/introduction.md +4 -4
- package/docs/ko/locale_mapper.md +4 -6
- package/docs/ko/mcp_server.md +13 -9
- package/docs/ko/packages/express-intlayer/t.md +4 -4
- package/docs/ko/packages/intlayer/getConfiguration.md +4 -4
- package/docs/ko/packages/intlayer/getEnumeration.md +4 -4
- package/docs/ko/packages/intlayer/getHTMLTextDir.md +4 -4
- package/docs/ko/packages/intlayer/getLocaleLang.md +4 -4
- package/docs/ko/packages/intlayer/getLocaleName.md +4 -4
- package/docs/ko/packages/intlayer/getLocalizedUrl.md +7 -16
- package/docs/ko/packages/intlayer/getMultilingualUrls.md +4 -4
- package/docs/ko/packages/intlayer/getPathWithoutLocale.md +4 -4
- package/docs/ko/packages/intlayer/getTranslation.md +4 -4
- package/docs/ko/packages/intlayer/getTranslationContent.md +4 -4
- package/docs/ko/packages/next-intlayer/t.md +4 -4
- package/docs/ko/packages/next-intlayer/useDictionary.md +4 -4
- package/docs/ko/packages/next-intlayer/useIntlayer.md +4 -4
- package/docs/ko/packages/next-intlayer/useLocale.md +4 -4
- package/docs/ko/packages/react-intlayer/t.md +4 -4
- package/docs/ko/packages/react-intlayer/useDictionary.md +4 -4
- package/docs/ko/packages/react-intlayer/useI18n.md +4 -4
- package/docs/ko/packages/react-intlayer/useIntlayer.md +4 -4
- package/docs/ko/packages/react-intlayer/useLocale.md +4 -4
- package/docs/ko/per_locale_file.md +4 -4
- package/docs/ko/roadmap.md +7 -5
- package/docs/ko/testing.md +4 -7
- package/docs/ko/vs_code_extension.md +13 -9
- package/docs/pt/CI_CD.md +4 -6
- package/docs/pt/autoFill.md +10 -8
- package/docs/pt/configuration.md +16 -22
- package/docs/pt/dictionary/content_file.md +7 -7
- package/docs/pt/dictionary/enumeration.md +4 -4
- package/docs/pt/dictionary/file.md +4 -4
- package/docs/pt/dictionary/function_fetching.md +4 -4
- package/docs/pt/dictionary/gender.md +4 -6
- package/docs/pt/dictionary/insertion.md +4 -4
- package/docs/pt/dictionary/translation.md +4 -4
- package/docs/pt/formatters.md +19 -33
- package/docs/pt/how_works_intlayer.md +5 -5
- package/docs/pt/index.md +4 -4
- package/docs/pt/interest_of_intlayer.md +7 -7
- package/docs/pt/intlayer_CMS.md +10 -8
- package/docs/pt/intlayer_cli.md +7 -7
- package/docs/pt/intlayer_visual_editor.md +5 -6
- package/docs/pt/intlayer_with_angular.md +8 -8
- package/docs/pt/intlayer_with_astro.md +244 -0
- package/docs/pt/intlayer_with_create_react_app.md +9 -8
- package/docs/pt/intlayer_with_express.md +8 -8
- package/docs/pt/intlayer_with_lynx+react.md +6 -6
- package/docs/pt/intlayer_with_nestjs.md +8 -10
- package/docs/pt/intlayer_with_nextjs_14.md +4 -4
- package/docs/pt/intlayer_with_nextjs_15.md +9 -8
- package/docs/pt/intlayer_with_nextjs_page_router.md +8 -8
- package/docs/pt/intlayer_with_nuxt.md +8 -8
- package/docs/pt/intlayer_with_react_native+expo.md +17 -26
- package/docs/pt/intlayer_with_react_router_v7.md +10 -18
- package/docs/pt/intlayer_with_tanstack.md +189 -266
- package/docs/pt/intlayer_with_vite+preact.md +15 -15
- package/docs/pt/intlayer_with_vite+react.md +16 -15
- package/docs/pt/intlayer_with_vite+solid.md +6 -6
- package/docs/pt/intlayer_with_vite+svelte.md +6 -6
- package/docs/pt/intlayer_with_vite+vue.md +15 -15
- package/docs/pt/introduction.md +4 -5
- package/docs/pt/locale_mapper.md +4 -6
- package/docs/pt/mcp_server.md +13 -9
- package/docs/pt/packages/express-intlayer/t.md +4 -4
- package/docs/pt/packages/intlayer/getConfiguration.md +4 -4
- package/docs/pt/packages/intlayer/getEnumeration.md +4 -4
- package/docs/pt/packages/intlayer/getHTMLTextDir.md +4 -4
- package/docs/pt/packages/intlayer/getLocaleLang.md +4 -4
- package/docs/pt/packages/intlayer/getLocaleName.md +4 -4
- package/docs/pt/packages/intlayer/getLocalizedUrl.md +4 -4
- package/docs/pt/packages/intlayer/getMultilingualUrls.md +4 -4
- package/docs/pt/packages/intlayer/getPathWithoutLocale.md +4 -4
- package/docs/pt/packages/intlayer/getTranslation.md +4 -4
- package/docs/pt/packages/intlayer/getTranslationContent.md +4 -4
- package/docs/pt/packages/next-intlayer/t.md +4 -4
- package/docs/pt/packages/next-intlayer/useDictionary.md +4 -4
- package/docs/pt/packages/next-intlayer/useIntlayer.md +4 -4
- package/docs/pt/packages/next-intlayer/useLocale.md +4 -4
- package/docs/pt/packages/react-intlayer/t.md +4 -4
- package/docs/pt/packages/react-intlayer/useDictionary.md +4 -4
- package/docs/pt/packages/react-intlayer/useI18n.md +4 -4
- package/docs/pt/packages/react-intlayer/useIntlayer.md +4 -4
- package/docs/pt/packages/react-intlayer/useLocale.md +4 -4
- package/docs/pt/per_locale_file.md +4 -4
- package/docs/pt/roadmap.md +7 -5
- package/docs/pt/testing.md +4 -7
- package/docs/pt/vs_code_extension.md +13 -9
- package/docs/ru/CI_CD.md +4 -6
- package/docs/ru/autoFill.md +10 -8
- package/docs/ru/configuration.md +16 -10
- package/docs/ru/dictionary/content_file.md +7 -7
- package/docs/ru/dictionary/enumeration.md +4 -4
- package/docs/ru/dictionary/file.md +4 -4
- package/docs/ru/dictionary/function_fetching.md +4 -4
- package/docs/ru/dictionary/gender.md +4 -6
- package/docs/ru/dictionary/insertion.md +4 -4
- package/docs/ru/dictionary/translation.md +4 -4
- package/docs/ru/formatters.md +20 -77
- package/docs/ru/how_works_intlayer.md +5 -5
- package/docs/ru/index.md +4 -4
- package/docs/ru/interest_of_intlayer.md +7 -7
- package/docs/ru/intlayer_CMS.md +10 -8
- package/docs/ru/intlayer_cli.md +7 -7
- package/docs/ru/intlayer_visual_editor.md +5 -5
- package/docs/ru/intlayer_with_angular.md +8 -8
- package/docs/ru/intlayer_with_astro.md +244 -0
- package/docs/ru/intlayer_with_create_react_app.md +9 -8
- package/docs/ru/intlayer_with_express.md +8 -8
- package/docs/ru/intlayer_with_lynx+react.md +6 -6
- package/docs/ru/intlayer_with_nestjs.md +8 -10
- package/docs/ru/intlayer_with_nextjs_14.md +4 -4
- package/docs/ru/intlayer_with_nextjs_15.md +9 -8
- package/docs/ru/intlayer_with_nextjs_page_router.md +8 -8
- package/docs/ru/intlayer_with_nuxt.md +8 -8
- package/docs/ru/intlayer_with_react_native+expo.md +17 -26
- package/docs/ru/intlayer_with_react_router_v7.md +197 -243
- package/docs/ru/intlayer_with_tanstack.md +203 -277
- package/docs/ru/intlayer_with_vite+preact.md +15 -15
- package/docs/ru/intlayer_with_vite+react.md +16 -15
- package/docs/ru/intlayer_with_vite+solid.md +6 -6
- package/docs/ru/intlayer_with_vite+svelte.md +6 -6
- package/docs/ru/intlayer_with_vite+vue.md +17 -17
- package/docs/ru/introduction.md +4 -4
- package/docs/ru/locale_mapper.md +4 -6
- package/docs/ru/mcp_server.md +13 -9
- package/docs/ru/packages/express-intlayer/t.md +4 -4
- package/docs/ru/packages/intlayer/getConfiguration.md +4 -4
- package/docs/ru/packages/intlayer/getEnumeration.md +4 -4
- package/docs/ru/packages/intlayer/getHTMLTextDir.md +4 -4
- package/docs/ru/packages/intlayer/getLocaleLang.md +4 -4
- package/docs/ru/packages/intlayer/getLocaleName.md +4 -4
- package/docs/ru/packages/intlayer/getLocalizedUrl.md +4 -4
- package/docs/ru/packages/intlayer/getMultilingualUrls.md +4 -4
- package/docs/ru/packages/intlayer/getPathWithoutLocale.md +4 -4
- package/docs/ru/packages/intlayer/getTranslation.md +4 -4
- package/docs/ru/packages/intlayer/getTranslationContent.md +4 -4
- package/docs/ru/packages/next-intlayer/t.md +4 -4
- package/docs/ru/packages/next-intlayer/useDictionary.md +4 -4
- package/docs/ru/packages/next-intlayer/useIntlayer.md +4 -4
- package/docs/ru/packages/next-intlayer/useLocale.md +4 -4
- package/docs/ru/packages/react-intlayer/t.md +4 -4
- package/docs/ru/packages/react-intlayer/useDictionary.md +4 -4
- package/docs/ru/packages/react-intlayer/useI18n.md +4 -4
- package/docs/ru/packages/react-intlayer/useIntlayer.md +4 -4
- package/docs/ru/packages/react-intlayer/useLocale.md +4 -4
- package/docs/ru/per_locale_file.md +4 -4
- package/docs/ru/roadmap.md +7 -5
- package/docs/ru/testing.md +4 -7
- package/docs/ru/vs_code_extension.md +13 -9
- package/docs/tr/CI_CD.md +4 -6
- package/docs/tr/autoFill.md +10 -8
- package/docs/tr/configuration.md +19 -22
- package/docs/tr/dictionary/condition.md +4 -10
- package/docs/tr/dictionary/content_file.md +7 -7
- package/docs/tr/dictionary/enumeration.md +4 -10
- package/docs/tr/dictionary/file.md +4 -10
- package/docs/tr/dictionary/function_fetching.md +4 -10
- package/docs/tr/dictionary/gender.md +4 -10
- package/docs/tr/dictionary/insertion.md +4 -10
- package/docs/tr/dictionary/markdown.md +4 -10
- package/docs/tr/dictionary/nesting.md +4 -10
- package/docs/tr/dictionary/translation.md +4 -10
- package/docs/tr/formatters.md +19 -33
- package/docs/tr/how_works_intlayer.md +6 -8
- package/docs/tr/index.md +5 -7
- package/docs/tr/interest_of_intlayer.md +7 -7
- package/docs/tr/intlayer_CMS.md +10 -8
- package/docs/tr/intlayer_cli.md +8 -8
- package/docs/tr/intlayer_visual_editor.md +5 -7
- package/docs/tr/intlayer_with_angular.md +10 -12
- package/docs/tr/intlayer_with_astro.md +244 -0
- package/docs/tr/intlayer_with_create_react_app.md +10 -12
- package/docs/tr/intlayer_with_express.md +9 -11
- package/docs/tr/intlayer_with_lynx+react.md +7 -9
- package/docs/tr/intlayer_with_nestjs.md +8 -10
- package/docs/tr/intlayer_with_nextjs_14.md +11 -11
- package/docs/tr/intlayer_with_nextjs_15.md +14 -13
- package/docs/tr/intlayer_with_nextjs_page_router.md +14 -14
- package/docs/tr/intlayer_with_nuxt.md +10 -12
- package/docs/tr/intlayer_with_react_native+expo.md +18 -29
- package/docs/tr/intlayer_with_react_router_v7.md +225 -270
- package/docs/tr/intlayer_with_tanstack.md +401 -304
- package/docs/tr/intlayer_with_vite+preact.md +18 -24
- package/docs/tr/intlayer_with_vite+react.md +18 -24
- package/docs/tr/intlayer_with_vite+solid.md +8 -14
- package/docs/tr/intlayer_with_vite+svelte.md +8 -14
- package/docs/tr/intlayer_with_vite+vue.md +18 -24
- package/docs/tr/introduction.md +5 -7
- package/docs/tr/locale_mapper.md +4 -6
- package/docs/tr/mcp_server.md +13 -9
- package/docs/tr/packages/express-intlayer/t.md +4 -6
- package/docs/tr/packages/intlayer/getConfiguration.md +4 -10
- package/docs/tr/packages/intlayer/getEnumeration.md +4 -10
- package/docs/tr/packages/intlayer/getHTMLTextDir.md +4 -10
- package/docs/tr/packages/intlayer/getLocaleLang.md +4 -10
- package/docs/tr/packages/intlayer/getLocaleName.md +4 -10
- package/docs/tr/packages/intlayer/getLocalizedUrl.md +4 -10
- package/docs/tr/packages/intlayer/getMultilingualUrls.md +4 -10
- package/docs/tr/packages/intlayer/getPathWithoutLocale.md +4 -10
- package/docs/tr/packages/intlayer/getTranslation.md +4 -10
- package/docs/tr/packages/intlayer/getTranslationContent.md +4 -10
- package/docs/tr/packages/next-intlayer/t.md +4 -6
- package/docs/tr/packages/next-intlayer/useDictionary.md +4 -6
- package/docs/tr/packages/next-intlayer/useIntlayer.md +4 -6
- package/docs/tr/packages/next-intlayer/useLocale.md +4 -6
- package/docs/tr/packages/react-intlayer/t.md +4 -6
- package/docs/tr/packages/react-intlayer/useDictionary.md +10 -273
- package/docs/tr/packages/react-intlayer/useI18n.md +5 -5
- package/docs/tr/packages/react-intlayer/useIntlayer.md +4 -6
- package/docs/tr/packages/react-intlayer/useLocale.md +4 -6
- package/docs/tr/per_locale_file.md +4 -6
- package/docs/tr/roadmap.md +11 -9
- package/docs/tr/testing.md +4 -7
- package/docs/tr/vs_code_extension.md +13 -9
- package/docs/zh/CI_CD.md +4 -6
- package/docs/zh/autoFill.md +10 -8
- package/docs/zh/configuration.md +19 -22
- package/docs/zh/dictionary/content_file.md +7 -7
- package/docs/zh/dictionary/enumeration.md +4 -4
- package/docs/zh/dictionary/file.md +4 -4
- package/docs/zh/dictionary/function_fetching.md +4 -4
- package/docs/zh/dictionary/gender.md +4 -6
- package/docs/zh/dictionary/insertion.md +4 -4
- package/docs/zh/dictionary/translation.md +4 -4
- package/docs/zh/formatters.md +19 -55
- package/docs/zh/how_works_intlayer.md +5 -5
- package/docs/zh/index.md +4 -4
- package/docs/zh/interest_of_intlayer.md +7 -7
- package/docs/zh/intlayer_CMS.md +10 -9
- package/docs/zh/intlayer_cli.md +7 -7
- package/docs/zh/intlayer_visual_editor.md +5 -6
- package/docs/zh/intlayer_with_angular.md +8 -8
- package/docs/zh/intlayer_with_astro.md +244 -0
- package/docs/zh/intlayer_with_create_react_app.md +9 -8
- package/docs/zh/intlayer_with_express.md +8 -8
- package/docs/zh/intlayer_with_lynx+react.md +6 -6
- package/docs/zh/intlayer_with_nestjs.md +8 -10
- package/docs/zh/intlayer_with_nextjs_14.md +8 -8
- package/docs/zh/intlayer_with_nextjs_15.md +9 -8
- package/docs/zh/intlayer_with_nextjs_page_router.md +8 -8
- package/docs/zh/intlayer_with_nuxt.md +8 -8
- package/docs/zh/intlayer_with_react_native+expo.md +25 -34
- package/docs/zh/intlayer_with_react_router_v7.md +204 -252
- package/docs/zh/intlayer_with_tanstack.md +211 -288
- package/docs/zh/intlayer_with_vite+preact.md +15 -15
- package/docs/zh/intlayer_with_vite+react.md +16 -15
- package/docs/zh/intlayer_with_vite+solid.md +6 -6
- package/docs/zh/intlayer_with_vite+svelte.md +6 -6
- package/docs/zh/intlayer_with_vite+vue.md +15 -15
- package/docs/zh/introduction.md +4 -4
- package/docs/zh/locale_mapper.md +4 -6
- package/docs/zh/mcp_server.md +13 -9
- package/docs/zh/packages/express-intlayer/t.md +4 -4
- package/docs/zh/packages/intlayer/getConfiguration.md +4 -4
- package/docs/zh/packages/intlayer/getEnumeration.md +4 -4
- package/docs/zh/packages/intlayer/getHTMLTextDir.md +4 -4
- package/docs/zh/packages/intlayer/getLocaleLang.md +4 -4
- package/docs/zh/packages/intlayer/getLocaleName.md +4 -4
- package/docs/zh/packages/intlayer/getLocalizedUrl.md +7 -16
- package/docs/zh/packages/intlayer/getMultilingualUrls.md +4 -4
- package/docs/zh/packages/intlayer/getPathWithoutLocale.md +4 -4
- package/docs/zh/packages/intlayer/getTranslation.md +4 -4
- package/docs/zh/packages/intlayer/getTranslationContent.md +4 -4
- package/docs/zh/packages/next-intlayer/t.md +4 -4
- package/docs/zh/packages/next-intlayer/useDictionary.md +4 -4
- package/docs/zh/packages/next-intlayer/useIntlayer.md +4 -4
- package/docs/zh/packages/next-intlayer/useLocale.md +4 -4
- package/docs/zh/packages/react-intlayer/t.md +4 -4
- package/docs/zh/packages/react-intlayer/useDictionary.md +4 -4
- package/docs/zh/packages/react-intlayer/useI18n.md +4 -4
- package/docs/zh/packages/react-intlayer/useIntlayer.md +4 -4
- package/docs/zh/packages/react-intlayer/useLocale.md +4 -4
- package/docs/zh/per_locale_file.md +4 -4
- package/docs/zh/roadmap.md +7 -5
- package/docs/zh/testing.md +4 -7
- package/docs/zh/vs_code_extension.md +13 -9
- package/frequent_questions/ar/bun_set_up.md +54 -0
- package/frequent_questions/de/bun_set_up.md +54 -0
- package/frequent_questions/en/bun_set_up.md +54 -0
- package/frequent_questions/en-GB/bun_set_up.md +54 -0
- package/frequent_questions/es/bun_set_up.md +54 -0
- package/frequent_questions/fr/bun_set_up.md +54 -0
- package/frequent_questions/hi/bun_set_up.md +55 -0
- package/frequent_questions/it/bun_set_up.md +55 -0
- package/frequent_questions/ja/bun_set_up.md +54 -0
- package/frequent_questions/ko/bun_set_up.md +54 -0
- package/frequent_questions/pt/bun_set_up.md +55 -0
- package/frequent_questions/ru/bun_set_up.md +55 -0
- package/frequent_questions/tr/bun_set_up.md +55 -0
- package/frequent_questions/zh/bun_set_up.md +54 -0
- package/package.json +42 -47
- package/src/blog.ts +16 -8
- package/src/common.ts +7 -8
- package/src/doc.ts +18 -8
- package/src/frequentQuestions.ts +23 -8
- package/src/generated/blog.entry.ts +152 -84
- package/src/generated/docs.entry.ts +536 -219
- package/src/generated/frequentQuestions.entry.ts +122 -56
- package/src/generated/legal.entry.ts +32 -24
- package/src/legal.ts +16 -8
- package/LICENSE +0 -202
- package/dist/cjs/index.cjs.map +0 -1
- package/dist/esm/index.mjs.map +0 -1
- package/dist/types/index.d.ts.map +0 -1
- package/docs/de/packages/@intlayer/api/index.md +0 -56
- package/docs/de/packages/@intlayer/chokidar/index.md +0 -56
- package/docs/de/packages/@intlayer/cli/index.md +0 -45
- package/docs/de/packages/@intlayer/config/index.md +0 -140
- package/docs/de/packages/@intlayer/core/index.md +0 -49
- package/docs/de/packages/@intlayer/design-system/index.md +0 -45
- package/docs/de/packages/@intlayer/dictionary-entry/index.md +0 -45
- package/docs/de/packages/@intlayer/editor/index.md +0 -45
- package/docs/de/packages/@intlayer/editor-react/index.md +0 -45
- package/docs/de/packages/@intlayer/webpack/index.md +0 -59
- package/docs/de/packages/angular-intlayer/index.md +0 -53
- package/docs/de/packages/express-intlayer/index.md +0 -284
- package/docs/de/packages/intlayer/index.md +0 -500
- package/docs/de/packages/intlayer-cli/index.md +0 -65
- package/docs/de/packages/intlayer-editor/index.md +0 -137
- package/docs/de/packages/lynx-intlayer/index.md +0 -83
- package/docs/de/packages/next-intlayer/index.md +0 -285
- package/docs/de/packages/nuxt-intlayer/index.md +0 -53
- package/docs/de/packages/preact-intlayer/index.md +0 -53
- package/docs/de/packages/react-intlayer/index.md +0 -280
- package/docs/de/packages/react-native-intlayer/index.md +0 -83
- package/docs/de/packages/react-scripts-intlayer/index.md +0 -80
- package/docs/de/packages/solid-intlayer/index.md +0 -54
- package/docs/de/packages/svelte-intlayer/index.md +0 -53
- package/docs/de/packages/vite-intlayer/index.md +0 -76
- package/docs/de/packages/vue-intlayer/index.md +0 -53
- package/docs/es/packages/angular-intlayer/index.md +0 -53
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
---
|
|
2
2
|
createdAt: 2025-09-04
|
|
3
|
-
updatedAt: 2025-
|
|
4
|
-
title:
|
|
5
|
-
description: 学习如何使用 Intlayer 为您的 React Router v7
|
|
3
|
+
updatedAt: 2025-10-03
|
|
4
|
+
title: 如何翻译您的React Router v7应用 – i18n指南 2025
|
|
5
|
+
description: 学习如何使用 Intlayer 为您的 React Router v7 应用添加国际化(i18n)。按照本综合指南,使您的应用支持多语言和基于区域的路由。
|
|
6
6
|
keywords:
|
|
7
7
|
- 国际化
|
|
8
8
|
- 文档
|
|
@@ -17,25 +17,31 @@ slugs:
|
|
|
17
17
|
- environment
|
|
18
18
|
- vite-and-react
|
|
19
19
|
- react-router-v7
|
|
20
|
-
applicationTemplate: https://github.com/
|
|
21
|
-
|
|
20
|
+
applicationTemplate: https://github.com/aymericzip/intlayer-react-router-v7-template
|
|
21
|
+
history:
|
|
22
|
+
- version: 6.1.5
|
|
23
|
+
date: 2025-10-03
|
|
24
|
+
changes: 更新文档
|
|
25
|
+
- version: 5.8.2
|
|
26
|
+
date: 2025-09-04
|
|
27
|
+
changes: 添加 React Router v7 支持
|
|
22
28
|
---
|
|
23
29
|
|
|
24
|
-
# 使用
|
|
30
|
+
# 使用Intlayer翻译您的React Router v7 | 国际化(i18n)
|
|
25
31
|
|
|
26
|
-
本指南演示了如何在 React Router v7 项目中集成 **Intlayer
|
|
32
|
+
本指南演示了如何在 React Router v7 项目中集成 **Intlayer**,实现无缝国际化,支持基于区域的路由、TypeScript 支持以及现代开发实践。
|
|
27
33
|
|
|
28
34
|
## 什么是 Intlayer?
|
|
29
35
|
|
|
30
|
-
**Intlayer**
|
|
36
|
+
**Intlayer** 是一个创新的开源国际化(i18n)库,旨在简化现代 Web 应用的多语言支持。
|
|
31
37
|
|
|
32
38
|
使用 Intlayer,您可以:
|
|
33
39
|
|
|
34
40
|
- **通过组件级声明式字典轻松管理翻译**。
|
|
35
41
|
- **动态本地化元数据、路由和内容**。
|
|
36
|
-
-
|
|
37
|
-
-
|
|
38
|
-
- **通过 React Router v7
|
|
42
|
+
- **确保 TypeScript 支持**,通过自动生成类型,提升自动补全和错误检测能力。
|
|
43
|
+
- **享受高级功能**,如动态区域检测和切换。
|
|
44
|
+
- **通过 React Router v7 的基于配置的路由系统启用区域感知路由**。
|
|
39
45
|
|
|
40
46
|
---
|
|
41
47
|
|
|
@@ -43,7 +49,7 @@ author: AydinTheFirst
|
|
|
43
49
|
|
|
44
50
|
### 第一步:安装依赖
|
|
45
51
|
|
|
46
|
-
|
|
52
|
+
使用您喜欢的包管理器安装必要的包:
|
|
47
53
|
|
|
48
54
|
```bash packageManager="npm"
|
|
49
55
|
npm install intlayer react-intlayer
|
|
@@ -62,10 +68,10 @@ pnpm add vite-intlayer --save-dev
|
|
|
62
68
|
提供国际化工具的核心包,用于配置管理、翻译、[内容声明](https://github.com/aymericzip/intlayer/blob/main/docs/docs/zh/dictionary/get_started.md)、转译以及[命令行工具](https://github.com/aymericzip/intlayer/blob/main/docs/docs/zh/intlayer_cli.md)。
|
|
63
69
|
|
|
64
70
|
- **react-intlayer**
|
|
65
|
-
将 Intlayer 集成到 React
|
|
71
|
+
将 Intlayer 集成到 React 应用中的包。它提供了 React 国际化的上下文提供者和钩子。
|
|
66
72
|
|
|
67
73
|
- **vite-intlayer**
|
|
68
|
-
包含用于将 Intlayer 集成到[Vite 打包工具](https://vite.dev/guide/why.html#why-bundle-for-production)的 Vite 插件,以及用于检测用户首选语言、管理 Cookie 和处理 URL 重定向的中间件。
|
|
74
|
+
包含用于将 Intlayer 集成到 [Vite 打包工具](https://vite.dev/guide/why.html#why-bundle-for-production) 的 Vite 插件,以及用于检测用户首选语言、管理 Cookie 和处理 URL 重定向的中间件。
|
|
69
75
|
|
|
70
76
|
### 第 2 步:项目配置
|
|
71
77
|
|
|
@@ -76,11 +82,8 @@ import { type IntlayerConfig, Locales } from "intlayer";
|
|
|
76
82
|
|
|
77
83
|
const config: IntlayerConfig = {
|
|
78
84
|
internationalization: {
|
|
79
|
-
defaultLocale: Locales.ENGLISH,
|
|
80
|
-
locales: [Locales.ENGLISH, Locales.
|
|
81
|
-
},
|
|
82
|
-
middleware: {
|
|
83
|
-
prefixDefault: true, // 始终在 URL 中添加默认语言前缀
|
|
85
|
+
defaultLocale: Locales.ENGLISH, // 默认语言
|
|
86
|
+
locales: [Locales.ENGLISH, Locales.FRENCH, Locales.SPANISH], // 支持的语言列表
|
|
84
87
|
},
|
|
85
88
|
};
|
|
86
89
|
|
|
@@ -93,11 +96,8 @@ import { Locales } from "intlayer";
|
|
|
93
96
|
/** @type {import('intlayer').IntlayerConfig} */
|
|
94
97
|
const config = {
|
|
95
98
|
internationalization: {
|
|
96
|
-
defaultLocale: Locales.ENGLISH,
|
|
97
|
-
locales: [Locales.ENGLISH, Locales.
|
|
98
|
-
},
|
|
99
|
-
middleware: {
|
|
100
|
-
prefixDefault: true,
|
|
99
|
+
defaultLocale: Locales.ENGLISH, // 默认语言
|
|
100
|
+
locales: [Locales.ENGLISH, Locales.FRENCH, Locales.SPANISH], // 支持的语言列表
|
|
101
101
|
},
|
|
102
102
|
};
|
|
103
103
|
|
|
@@ -108,75 +108,68 @@ export default config;
|
|
|
108
108
|
const { Locales } = require("intlayer");
|
|
109
109
|
|
|
110
110
|
/** @type {import('intlayer').IntlayerConfig} */
|
|
111
|
-
//
|
|
111
|
+
// 配置对象,定义国际化设置
|
|
112
112
|
const config = {
|
|
113
113
|
internationalization: {
|
|
114
|
-
defaultLocale: Locales.ENGLISH, //
|
|
115
|
-
locales: [Locales.ENGLISH, Locales.
|
|
116
|
-
},
|
|
117
|
-
middleware: {
|
|
118
|
-
prefixDefault: true, // 默认语言的 URL 也加前缀
|
|
114
|
+
defaultLocale: Locales.ENGLISH, // 默认语言
|
|
115
|
+
locales: [Locales.ENGLISH, Locales.FRENCH, Locales.SPANISH], // 支持的语言列表
|
|
119
116
|
},
|
|
120
117
|
};
|
|
121
118
|
|
|
122
119
|
module.exports = config;
|
|
123
120
|
```
|
|
124
121
|
|
|
125
|
-
> 通过此配置文件,您可以设置本地化的 URL、中间件重定向、cookie
|
|
126
|
-
|
|
127
|
-
### 第3步:配置 React Router v7 路由
|
|
128
|
-
|
|
129
|
-
设置支持多语言的路由配置:
|
|
130
|
-
|
|
131
|
-
```typescript fileName="app/routes.ts" codeFormat="typescript"
|
|
132
|
-
import { layout, route, type RouteConfig } from "@react-router/dev/routes";
|
|
133
|
-
|
|
134
|
-
export default [
|
|
135
|
-
layout("routes/layout.tsx", [
|
|
136
|
-
route("/", "routes/page.tsx"), // 根页面 - 重定向到语言版本
|
|
137
|
-
route("/:lang", "routes/[lang]/page.tsx"), // 本地化首页
|
|
138
|
-
route("/:lang/about", "routes/[lang]/about/page.tsx"), // 本地化关于页面
|
|
139
|
-
]),
|
|
140
|
-
] satisfies RouteConfig;
|
|
141
|
-
```
|
|
122
|
+
> 通过此配置文件,您可以设置本地化的 URL、中间件重定向、cookie 名称、内容声明的位置和扩展名,禁用控制台中的 Intlayer 日志等。有关可用参数的完整列表,请参阅[配置文档](https://github.com/aymericzip/intlayer/blob/main/docs/docs/zh/configuration.md)。
|
|
142
123
|
|
|
143
|
-
###
|
|
124
|
+
### 第三步:在您的 Vite 配置中集成 Intlayer
|
|
144
125
|
|
|
145
|
-
将 intlayer
|
|
126
|
+
将 intlayer 插件添加到您的配置中:
|
|
146
127
|
|
|
147
|
-
```typescript fileName="vite.config.ts"
|
|
128
|
+
```typescript fileName="vite.config.ts"
|
|
148
129
|
import { reactRouter } from "@react-router/dev/vite";
|
|
149
130
|
import { defineConfig } from "vite";
|
|
150
|
-
import {
|
|
131
|
+
import { intlayer } from "vite-intlayer";
|
|
151
132
|
import tsconfigPaths from "vite-tsconfig-paths";
|
|
152
133
|
|
|
153
134
|
export default defineConfig({
|
|
154
|
-
plugins: [
|
|
155
|
-
reactRouter(),
|
|
156
|
-
tsconfigPaths(),
|
|
157
|
-
intlayer(),
|
|
158
|
-
intlayerMiddlewarePlugin(),
|
|
159
|
-
],
|
|
135
|
+
plugins: [reactRouter(), tsconfigPaths(), intlayer()],
|
|
160
136
|
});
|
|
161
137
|
```
|
|
162
138
|
|
|
163
|
-
> `intlayer()`
|
|
139
|
+
> `intlayer()` Vite 插件用于将 Intlayer 集成到 Vite 中。它确保内容声明文件的构建,并在开发模式下监视这些文件。它在 Vite 应用中定义了 Intlayer 的环境变量。此外,它还提供别名以优化性能。
|
|
140
|
+
|
|
141
|
+
### 第4步:配置 React Router v7 路由
|
|
142
|
+
|
|
143
|
+
设置支持多语言的路由配置:
|
|
164
144
|
|
|
165
|
-
|
|
145
|
+
```typescript fileName="app/routes.ts"
|
|
146
|
+
import { layout, route, type RouteConfig } from "@react-router/dev/routes";
|
|
166
147
|
|
|
167
|
-
|
|
148
|
+
export default [
|
|
149
|
+
layout("routes/layout.tsx", [
|
|
150
|
+
route("/:lang?", "routes/page.tsx"), // 本地化主页
|
|
151
|
+
route("/:lang?/about", "routes/about/page.tsx"), // 本地化关于页面
|
|
152
|
+
]),
|
|
153
|
+
] satisfies RouteConfig;
|
|
154
|
+
```
|
|
155
|
+
|
|
156
|
+
### 第5步:创建布局组件
|
|
157
|
+
|
|
158
|
+
设置根布局和特定语言环境的布局:
|
|
168
159
|
|
|
169
160
|
#### 根布局
|
|
170
161
|
|
|
171
|
-
```tsx fileName="app/routes/layout.tsx"
|
|
172
|
-
tsx;
|
|
173
|
-
// app/routes/layout.tsx
|
|
174
|
-
import { Outlet } from "react-router";
|
|
162
|
+
```tsx fileName="app/routes/layout.tsx"
|
|
175
163
|
import { IntlayerProvider } from "react-intlayer";
|
|
164
|
+
import { Outlet } from "react-router";
|
|
165
|
+
|
|
166
|
+
import type { Route } from "./+types/layout";
|
|
167
|
+
|
|
168
|
+
export default function RootLayout({ params }: Route.ComponentProps) {
|
|
169
|
+
const { locale } = params;
|
|
176
170
|
|
|
177
|
-
export default function RootLayout() {
|
|
178
171
|
return (
|
|
179
|
-
<IntlayerProvider>
|
|
172
|
+
<IntlayerProvider locale={locale}>
|
|
180
173
|
<Outlet />
|
|
181
174
|
</IntlayerProvider>
|
|
182
175
|
);
|
|
@@ -187,7 +180,7 @@ export default function RootLayout() {
|
|
|
187
180
|
|
|
188
181
|
创建并管理您的内容声明以存储翻译:
|
|
189
182
|
|
|
190
|
-
```tsx fileName="app/routes/[lang]/page.content.ts"
|
|
183
|
+
```tsx fileName="app/routes/[lang]/page.content.ts"
|
|
191
184
|
import { t, type Dictionary } from "intlayer";
|
|
192
185
|
|
|
193
186
|
const pageContent = {
|
|
@@ -195,19 +188,23 @@ const pageContent = {
|
|
|
195
188
|
content: {
|
|
196
189
|
title: t({
|
|
197
190
|
en: "Welcome to React Router v7 + Intlayer",
|
|
198
|
-
|
|
191
|
+
es: "Bienvenido a React Router v7 + Intlayer",
|
|
192
|
+
fr: "Bienvenue sur React Router v7 + Intlayer",
|
|
199
193
|
}),
|
|
200
194
|
description: t({
|
|
201
195
|
en: "Build multilingual applications with ease using React Router v7 and Intlayer.",
|
|
202
|
-
|
|
196
|
+
es: "Cree aplicaciones multilingües fácilmente usando React Router v7 y Intlayer.",
|
|
197
|
+
fr: "Créez des applications multilingues facilement avec React Router v7 et Intlayer.",
|
|
203
198
|
}),
|
|
204
199
|
aboutLink: t({
|
|
205
200
|
en: "了解我们",
|
|
206
|
-
|
|
201
|
+
es: "Aprender Sobre Nosotros",
|
|
202
|
+
fr: "En savoir plus sur nous",
|
|
207
203
|
}),
|
|
208
204
|
homeLink: t({
|
|
209
205
|
en: "首页",
|
|
210
|
-
|
|
206
|
+
es: "Inicio",
|
|
207
|
+
fr: "Accueil",
|
|
211
208
|
}),
|
|
212
209
|
},
|
|
213
210
|
} satisfies Dictionary;
|
|
@@ -215,163 +212,163 @@ const pageContent = {
|
|
|
215
212
|
export default pageContent;
|
|
216
213
|
```
|
|
217
214
|
|
|
218
|
-
>
|
|
215
|
+
> 您的内容声明可以定义在应用程序中的任何位置,只要它们被包含在 `contentDir` 目录中(默认是 `./app`)。并且文件扩展名需匹配内容声明文件扩展名(默认是 `.content.{json,ts,tsx,js,jsx,mjs,mjx,cjs,cjx}`)。
|
|
219
216
|
|
|
220
217
|
> 更多详情,请参阅[内容声明文档](https://github.com/aymericzip/intlayer/blob/main/docs/docs/zh/dictionary/get_started.md)。
|
|
221
218
|
|
|
222
219
|
### 第7步:创建支持多语言的组件
|
|
223
220
|
|
|
224
|
-
创建一个 `LocalizedLink`
|
|
225
|
-
|
|
226
|
-
```tsx fileName="app/components/localized-link.tsx" codeFormat="typescript"
|
|
227
|
-
// app/components/localized-link.tsx
|
|
228
|
-
import { getLocalizedUrl } from "intlayer";
|
|
229
|
-
import { useLocale } from "react-intlayer";
|
|
230
|
-
import React from "react";
|
|
231
|
-
import { Link, useLocation } from "react-router";
|
|
221
|
+
创建一个 `LocalizedLink` 组件,用于支持多语言的导航:
|
|
232
222
|
|
|
233
|
-
|
|
223
|
+
```tsx fileName="app/components/localized-link.tsx"
|
|
224
|
+
import type { FC } from "react";
|
|
234
225
|
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
226
|
+
import { getLocalizedUrl, type LocalesValues } from "intlayer";
|
|
227
|
+
import { useLocale } from "react-intlayer";
|
|
228
|
+
import { Link, type LinkProps, type To } from "react-router";
|
|
238
229
|
|
|
239
|
-
|
|
240
|
-
/^([a-z][a-z0-9+.-]*:)?\/\//i.test(path) || path.startsWith("mailto:");
|
|
230
|
+
const isExternalLink = (to: string) => /^(https?:)?\/\//.test(to); // 判断是否为外部链接
|
|
241
231
|
|
|
232
|
+
export const locacalizeTo = (to: To, locale: LocalesValues): To => {
|
|
242
233
|
if (typeof to === "string") {
|
|
243
|
-
if (
|
|
244
|
-
return
|
|
234
|
+
if (isExternalLink(to)) {
|
|
235
|
+
return to; // 如果是外部链接,直接返回
|
|
245
236
|
}
|
|
246
|
-
|
|
237
|
+
|
|
238
|
+
return getLocalizedUrl(to, locale); // 获取本地化的URL
|
|
247
239
|
}
|
|
248
240
|
|
|
249
|
-
if (to
|
|
250
|
-
|
|
251
|
-
if (pathname && pathname.startsWith("/") && !isExternal(pathname)) {
|
|
252
|
-
return (
|
|
253
|
-
<Link
|
|
254
|
-
to={{ ...to, pathname: getLocalizedUrl(pathname, locale) }}
|
|
255
|
-
{...props}
|
|
256
|
-
/>
|
|
257
|
-
);
|
|
258
|
-
}
|
|
259
|
-
return <Link to={to} {...props} />;
|
|
241
|
+
if (isExternalLink(to.pathname ?? "")) {
|
|
242
|
+
return to; // 如果路径名是外部链接,直接返回
|
|
260
243
|
}
|
|
261
244
|
|
|
262
|
-
return
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
);
|
|
268
|
-
}
|
|
269
|
-
```
|
|
245
|
+
return {
|
|
246
|
+
...to,
|
|
247
|
+
pathname: getLocalizedUrl(to.pathname ?? "", locale), // 本地化路径名
|
|
248
|
+
};
|
|
249
|
+
};
|
|
270
250
|
|
|
271
|
-
|
|
251
|
+
export const LocalizedLink: FC<LinkProps> = (props) => {
|
|
252
|
+
const { locale } = useLocale(); // 获取当前语言环境
|
|
272
253
|
|
|
273
|
-
|
|
254
|
+
return <Link {...props} to={locacalizeTo(props.to, locale)} />;
|
|
255
|
+
};
|
|
256
|
+
```
|
|
274
257
|
|
|
275
|
-
|
|
258
|
+
如果你想导航到本地化路由,可以使用 `useLocalizedNavigate` 钩子:
|
|
276
259
|
|
|
277
|
-
```tsx fileName="app/
|
|
278
|
-
|
|
279
|
-
import {
|
|
280
|
-
import { Navigate } from "react-router";
|
|
260
|
+
```tsx fileName="app/hooks/useLocalizedNavigate.ts"
|
|
261
|
+
import { useLocale } from "intlayer";
|
|
262
|
+
import { type NavigateOptions, type To, useNavigate } from "react-router";
|
|
281
263
|
|
|
282
|
-
|
|
264
|
+
import { locacalizeTo } from "~/components/localized-link";
|
|
265
|
+
|
|
266
|
+
export const useLocalizedNavigate = () => {
|
|
267
|
+
const navigate = useNavigate();
|
|
283
268
|
const { locale } = useLocale();
|
|
284
269
|
|
|
285
|
-
|
|
286
|
-
|
|
270
|
+
const localizedNavigate = (to: To, options?: NavigateOptions) => {
|
|
271
|
+
const localedTo = locacalizeTo(to, locale);
|
|
272
|
+
|
|
273
|
+
navigate(localedTo, options);
|
|
274
|
+
};
|
|
275
|
+
|
|
276
|
+
return localizedNavigate;
|
|
277
|
+
};
|
|
287
278
|
```
|
|
288
279
|
|
|
280
|
+
### 第8步:在你的页面中使用 Intlayer
|
|
281
|
+
|
|
282
|
+
在您的整个应用程序中访问内容字典:
|
|
283
|
+
|
|
289
284
|
#### 本地化主页
|
|
290
285
|
|
|
291
|
-
```tsx fileName="app/routes/[lang]/page.tsx"
|
|
286
|
+
```tsx fileName="app/routes/[lang]/page.tsx"
|
|
292
287
|
import { useIntlayer } from "react-intlayer";
|
|
293
|
-
import LocalizedLink from "~/components/localized-link";
|
|
288
|
+
import { LocalizedLink } from "~/components/localized-link";
|
|
294
289
|
|
|
295
290
|
export default function Page() {
|
|
296
|
-
const
|
|
291
|
+
const { title, description, aboutLink } = useIntlayer("page");
|
|
297
292
|
|
|
298
293
|
return (
|
|
299
|
-
<div
|
|
300
|
-
<h1>{
|
|
301
|
-
<p>{
|
|
302
|
-
<nav
|
|
303
|
-
<LocalizedLink
|
|
304
|
-
to="/about"
|
|
305
|
-
style={{
|
|
306
|
-
display: "inline-block",
|
|
307
|
-
padding: "0.5rem 1rem",
|
|
308
|
-
backgroundColor: "#007bff",
|
|
309
|
-
color: "white",
|
|
310
|
-
textDecoration: "none",
|
|
311
|
-
borderRadius: "4px",
|
|
312
|
-
}}
|
|
313
|
-
>
|
|
314
|
-
{content.aboutLink}
|
|
315
|
-
</LocalizedLink>
|
|
294
|
+
<div>
|
|
295
|
+
<h1>{title}</h1>
|
|
296
|
+
<p>{description}</p>
|
|
297
|
+
<nav>
|
|
298
|
+
<LocalizedLink to="/about">{aboutLink}</LocalizedLink>
|
|
316
299
|
</nav>
|
|
317
300
|
</div>
|
|
318
301
|
);
|
|
319
302
|
}
|
|
320
303
|
```
|
|
321
304
|
|
|
322
|
-
> 想了解更多关于 `useIntlayer`
|
|
305
|
+
> 想了解更多关于 `useIntlayer` 钩子的内容,请参阅[文档](https://github.com/aymericzip/intlayer/blob/main/docs/docs/zh/packages/react-intlayer/useIntlayer.md)。
|
|
323
306
|
|
|
324
307
|
### 第9步:创建语言切换组件
|
|
325
308
|
|
|
326
309
|
创建一个组件,允许用户切换语言:
|
|
327
310
|
|
|
328
|
-
```tsx fileName="app/components/locale-switcher.tsx"
|
|
329
|
-
import {
|
|
330
|
-
import { useLocale } from "react-intlayer";
|
|
331
|
-
import { useLocation, useNavigate } from "react-router";
|
|
311
|
+
```tsx fileName="app/components/locale-switcher.tsx"
|
|
312
|
+
import type { FC } from "react";
|
|
332
313
|
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
314
|
+
import {
|
|
315
|
+
getHTMLTextDir,
|
|
316
|
+
getLocaleName,
|
|
317
|
+
getLocalizedUrl,
|
|
318
|
+
getPathWithoutLocale,
|
|
319
|
+
} from "intlayer";
|
|
320
|
+
import { setLocaleCookie, useIntlayer, useLocale } from "react-intlayer";
|
|
321
|
+
import { Link, useLocation } from "react-router";
|
|
337
322
|
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
};
|
|
323
|
+
export const LocaleSwitcher: FC = () => {
|
|
324
|
+
const { localeSwitcherLabel } = useIntlayer("locale-switcher"); // 使用 useIntlayer 钩子获取本地化标签
|
|
325
|
+
const { pathname } = useLocation(); // 获取当前路径名
|
|
326
|
+
|
|
327
|
+
const { availableLocales, locale } = useLocale(); // 获取可用语言和当前语言
|
|
328
|
+
|
|
329
|
+
const pathWithoutLocale = getPathWithoutLocale(pathname); // 获取不带语言前缀的路径
|
|
346
330
|
|
|
347
331
|
return (
|
|
348
|
-
<
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
332
|
+
<ol>
|
|
333
|
+
{availableLocales.map((localeItem) => (
|
|
334
|
+
<li key={localeItem}>
|
|
335
|
+
<Link
|
|
336
|
+
aria-current={localeItem === locale ? "page" : undefined}
|
|
337
|
+
aria-label={`${localeSwitcherLabel.value} ${getLocaleName(localeItem)}`}
|
|
338
|
+
onClick={() => setLocaleCookie(localeItem)}
|
|
339
|
+
to={getLocalizedUrl(pathWithoutLocale, localeItem)}
|
|
340
|
+
>
|
|
341
|
+
<span>
|
|
342
|
+
{/* 语言环境 - 例如 FR */}
|
|
343
|
+
{localeItem}
|
|
344
|
+
</span>
|
|
345
|
+
<span>
|
|
346
|
+
{/* 语言在其自身语言环境中的名称 - 例如 Français */}
|
|
347
|
+
{getLocaleName(localeItem, locale)}
|
|
348
|
+
</span>
|
|
349
|
+
<span dir={getHTMLTextDir(localeItem)} lang={localeItem}>
|
|
350
|
+
{/* 语言在当前语言环境中的名称 - 例如当前语言环境为 Locales.SPANISH 时显示 Francés */}
|
|
351
|
+
{getLocaleName(localeItem)}
|
|
352
|
+
</span>
|
|
353
|
+
<span dir="ltr" lang={Locales.ENGLISH}>
|
|
354
|
+
{/* 语言的英文名称 - 例如 French */}
|
|
355
|
+
{getLocaleName(localeItem, Locales.ENGLISH)}
|
|
356
|
+
</span>
|
|
357
|
+
</Link>
|
|
358
|
+
</li>
|
|
359
|
+
))}
|
|
360
|
+
</ol>
|
|
363
361
|
);
|
|
364
|
-
}
|
|
362
|
+
};
|
|
365
363
|
```
|
|
366
364
|
|
|
367
|
-
> 想了解更多关于 `useLocale`
|
|
365
|
+
> 想了解更多关于 `useLocale` 钩子的内容,请参阅[文档](https://github.com/aymericzip/intlayer/blob/main/docs/docs/zh/packages/react-intlayer/useLocale.md)。
|
|
368
366
|
|
|
369
|
-
### 第10步:添加
|
|
367
|
+
### 第10步:添加HTML属性管理(可选)
|
|
370
368
|
|
|
371
|
-
创建一个钩子来管理
|
|
369
|
+
创建一个钩子来管理HTML的 lang 和 dir 属性:
|
|
372
370
|
|
|
373
|
-
```tsx fileName="app/hooks/useI18nHTMLAttributes.tsx"
|
|
374
|
-
// app/hooks/useI18nHTMLAttributes.tsx
|
|
371
|
+
```tsx fileName="app/hooks/useI18nHTMLAttributes.tsx"
|
|
375
372
|
import { getHTMLTextDir } from "intlayer";
|
|
376
373
|
import { useEffect } from "react";
|
|
377
374
|
import { useLocale } from "react-intlayer";
|
|
@@ -388,15 +385,14 @@ export const useI18nHTMLAttributes = () => {
|
|
|
388
385
|
|
|
389
386
|
然后在你的根组件中使用它:
|
|
390
387
|
|
|
391
|
-
```tsx fileName="app/
|
|
392
|
-
// app/routes/layout.tsx
|
|
388
|
+
```tsx fileName="app/routes/layout.tsx"
|
|
393
389
|
import { Outlet } from "react-router";
|
|
394
390
|
import { IntlayerProvider } from "react-intlayer";
|
|
395
391
|
|
|
396
|
-
import { useI18nHTMLAttributes } from "app/hooks/useI18nHTMLAttributes"; //
|
|
392
|
+
import { useI18nHTMLAttributes } from "app/hooks/useI18nHTMLAttributes"; // 导入该钩子
|
|
397
393
|
|
|
398
394
|
export default function RootLayout() {
|
|
399
|
-
useI18nHTMLAttributes(); //
|
|
395
|
+
useI18nHTMLAttributes(); // 调用该钩子
|
|
400
396
|
|
|
401
397
|
return (
|
|
402
398
|
<IntlayerProvider>
|
|
@@ -406,57 +402,48 @@ export default function RootLayout() {
|
|
|
406
402
|
}
|
|
407
403
|
```
|
|
408
404
|
|
|
409
|
-
### 第11
|
|
410
|
-
|
|
411
|
-
构建内容字典并运行您的应用程序:
|
|
405
|
+
### 第11步:添加中间件(可选)
|
|
412
406
|
|
|
413
|
-
|
|
414
|
-
# 构建 Intlayer 字典
|
|
415
|
-
npm run intlayer:build
|
|
407
|
+
你也可以使用 `intlayerMiddleware` 为你的应用添加服务器端路由。该插件会根据 URL 自动检测当前的语言环境,并设置相应的语言环境 cookie。如果未指定语言环境,插件将根据用户浏览器的语言偏好确定最合适的语言环境。如果仍未检测到语言环境,则会重定向到默认语言环境。
|
|
416
408
|
|
|
417
|
-
|
|
418
|
-
npm run dev
|
|
419
|
-
```
|
|
409
|
+
> 注意,要在生产环境中使用 `intlayerMiddleware`,你需要将 `vite-intlayer` 包从 `devDependencies` 切换到 `dependencies`。
|
|
420
410
|
|
|
421
|
-
```
|
|
422
|
-
|
|
423
|
-
|
|
411
|
+
```typescript {3,7} fileName="vite.config.ts"
|
|
412
|
+
import { defineConfig } from "vite";
|
|
413
|
+
import react from "@vitejs/plugin-react-swc";
|
|
414
|
+
import { intlayer, intlayerMiddleware } from "vite-intlayer";
|
|
424
415
|
|
|
425
|
-
|
|
426
|
-
|
|
416
|
+
// https://vitejs.dev/config/
|
|
417
|
+
export default defineConfig({
|
|
418
|
+
plugins: [react(), intlayer(), intlayerMiddleware()],
|
|
419
|
+
});
|
|
427
420
|
```
|
|
428
421
|
|
|
429
|
-
|
|
430
|
-
# 构建 Intlayer 字典
|
|
431
|
-
yarn intlayer:build
|
|
432
|
-
|
|
433
|
-
# 启动开发服务器
|
|
434
|
-
yarn dev
|
|
435
|
-
```
|
|
422
|
+
---
|
|
436
423
|
|
|
437
|
-
|
|
424
|
+
## 配置 TypeScript
|
|
438
425
|
|
|
439
|
-
Intlayer 使用模块增强来利用 TypeScript
|
|
426
|
+
Intlayer 使用模块增强来利用 TypeScript 的优势,使您的代码库更强大。
|
|
440
427
|
|
|
441
428
|
确保您的 TypeScript 配置包含自动生成的类型:
|
|
442
429
|
|
|
443
430
|
```json5 fileName="tsconfig.json"
|
|
444
431
|
{
|
|
445
|
-
|
|
446
|
-
// ... 您现有的 TypeScript 配置
|
|
447
|
-
},
|
|
432
|
+
// ... 您现有的配置
|
|
448
433
|
include: [
|
|
449
|
-
// ...
|
|
434
|
+
// ... 您现有的包含项
|
|
450
435
|
".intlayer/**/*.ts", // 包含自动生成的类型
|
|
451
436
|
],
|
|
452
437
|
}
|
|
453
438
|
```
|
|
454
439
|
|
|
455
|
-
|
|
440
|
+
---
|
|
441
|
+
|
|
442
|
+
## Git 配置
|
|
456
443
|
|
|
457
|
-
建议忽略 Intlayer
|
|
444
|
+
建议忽略 Intlayer 生成的文件,这样可以避免将它们提交到您的 Git 仓库。
|
|
458
445
|
|
|
459
|
-
|
|
446
|
+
为此,您可以在 `.gitignore` 文件中添加以下指令:
|
|
460
447
|
|
|
461
448
|
```plaintext fileName=".gitignore"
|
|
462
449
|
# 忽略 Intlayer 生成的文件
|
|
@@ -465,35 +452,6 @@ Intlayer 使用模块增强来利用 TypeScript 的优势,使您的代码库
|
|
|
465
452
|
|
|
466
453
|
---
|
|
467
454
|
|
|
468
|
-
## 生产环境部署
|
|
469
|
-
|
|
470
|
-
部署你的应用时:
|
|
471
|
-
|
|
472
|
-
1. **构建你的应用:**
|
|
473
|
-
|
|
474
|
-
```bash
|
|
475
|
-
npm run build
|
|
476
|
-
```
|
|
477
|
-
|
|
478
|
-
2. **构建 Intlayer 字典:**
|
|
479
|
-
|
|
480
|
-
```bash
|
|
481
|
-
npm run intlayer:build
|
|
482
|
-
```
|
|
483
|
-
|
|
484
|
-
3. **如果在生产环境使用中间件,需将 `vite-intlayer` 移动到依赖中:**
|
|
485
|
-
```bash
|
|
486
|
-
npm install vite-intlayer --save
|
|
487
|
-
```
|
|
488
|
-
|
|
489
|
-
您的应用程序现在将支持:
|
|
490
|
-
|
|
491
|
-
- **URL 结构**:`/en`,`/en/about`,`/tr`,`/tr/about`
|
|
492
|
-
- 基于浏览器偏好的**自动语言环境检测**
|
|
493
|
-
- 使用 React Router v7 的**语言环境感知路由**
|
|
494
|
-
- 具有自动生成类型的**TypeScript 支持**
|
|
495
|
-
- 具有正确语言环境处理的**服务器端渲染**
|
|
496
|
-
|
|
497
455
|
## VS Code 扩展
|
|
498
456
|
|
|
499
457
|
为了提升您使用 Intlayer 的开发体验,您可以安装官方的 **Intlayer VS Code 扩展**。
|
|
@@ -502,18 +460,18 @@ Intlayer 使用模块增强来利用 TypeScript 的优势,使您的代码库
|
|
|
502
460
|
|
|
503
461
|
该扩展提供:
|
|
504
462
|
|
|
505
|
-
-
|
|
506
|
-
-
|
|
507
|
-
-
|
|
508
|
-
-
|
|
463
|
+
- 翻译键的**自动补全**。
|
|
464
|
+
- 缺失翻译的**实时错误检测**。
|
|
465
|
+
- 翻译内容的**内联预览**。
|
|
466
|
+
- 轻松创建和更新翻译的**快速操作**。
|
|
509
467
|
|
|
510
|
-
有关如何使用该扩展的更多详细信息,请参阅[Intlayer VS Code 扩展文档](https://intlayer.org/doc/vs-code-extension)。
|
|
468
|
+
有关如何使用该扩展的更多详细信息,请参阅 [Intlayer VS Code 扩展文档](https://intlayer.org/doc/vs-code-extension)。
|
|
511
469
|
|
|
512
470
|
---
|
|
513
471
|
|
|
514
472
|
## 深入了解
|
|
515
473
|
|
|
516
|
-
|
|
474
|
+
要更进一步,您可以实现[可视化编辑器](https://github.com/aymericzip/intlayer/blob/main/docs/docs/zh/intlayer_visual_editor.md)或使用[内容管理系统(CMS)](https://github.com/aymericzip/intlayer/blob/main/docs/docs/zh/intlayer_CMS.md)来外部化您的内容。
|
|
517
475
|
|
|
518
476
|
---
|
|
519
477
|
|
|
@@ -526,10 +484,4 @@ Intlayer 使用模块增强来利用 TypeScript 的优势,使您的代码库
|
|
|
526
484
|
- [内容声明](https://github.com/aymericzip/intlayer/blob/main/docs/docs/zh/dictionary/get_started.md)
|
|
527
485
|
- [配置](https://github.com/aymericzip/intlayer/blob/main/docs/docs/zh/configuration.md)
|
|
528
486
|
|
|
529
|
-
本综合指南提供了将 Intlayer 与 React Router v7
|
|
530
|
-
|
|
531
|
-
## 文档历史
|
|
532
|
-
|
|
533
|
-
| 版本 | 日期 | 变更内容 |
|
|
534
|
-
| ----- | --------- | ------------------------- |
|
|
535
|
-
| 5.8.2 | 2025-09-4 | 新增 React Router v7 支持 |
|
|
487
|
+
本综合指南提供了将 Intlayer 与 React Router v7 集成所需的一切,支持完全国际化的应用程序,具备基于区域设置的路由和 TypeScript 支持。
|