@intlayer/docs 7.5.6 → 7.5.8
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 +8 -4
- package/blog/ar/intlayer_with_next-i18next.md +8 -4
- package/blog/ar/intlayer_with_next-intl.md +8 -4
- package/blog/ar/intlayer_with_react-i18next.md +8 -4
- package/blog/ar/intlayer_with_react-intl.md +8 -4
- package/blog/ar/intlayer_with_vue-i18n.md +8 -4
- package/blog/de/intlayer_with_i18next.md +8 -4
- package/blog/de/intlayer_with_next-i18next.md +8 -4
- package/blog/de/intlayer_with_next-intl.md +8 -4
- package/blog/de/intlayer_with_react-i18next.md +8 -4
- package/blog/de/intlayer_with_react-intl.md +8 -4
- package/blog/de/intlayer_with_vue-i18n.md +8 -4
- package/blog/en/intlayer_with_i18next.md +8 -4
- package/blog/en/intlayer_with_next-i18next.md +8 -4
- package/blog/en/intlayer_with_next-intl.md +8 -4
- package/blog/en/intlayer_with_react-i18next.md +8 -4
- package/blog/en/intlayer_with_react-intl.md +8 -4
- package/blog/en/intlayer_with_vue-i18n.md +8 -4
- package/blog/en-GB/intlayer_with_i18next.md +8 -4
- package/blog/en-GB/intlayer_with_next-i18next.md +8 -4
- package/blog/en-GB/intlayer_with_next-intl.md +8 -4
- package/blog/en-GB/intlayer_with_react-i18next.md +8 -4
- package/blog/en-GB/intlayer_with_react-intl.md +8 -4
- package/blog/en-GB/intlayer_with_vue-i18n.md +8 -4
- package/blog/es/intlayer_with_i18next.md +8 -4
- package/blog/es/intlayer_with_next-i18next.md +8 -4
- package/blog/es/intlayer_with_next-intl.md +8 -4
- package/blog/es/intlayer_with_react-i18next.md +8 -4
- package/blog/es/intlayer_with_react-intl.md +8 -4
- package/blog/es/intlayer_with_vue-i18n.md +8 -4
- package/blog/fr/intlayer_with_i18next.md +8 -4
- package/blog/fr/intlayer_with_next-i18next.md +8 -4
- package/blog/fr/intlayer_with_next-intl.md +8 -4
- package/blog/fr/intlayer_with_react-i18next.md +8 -4
- package/blog/fr/intlayer_with_react-intl.md +8 -4
- package/blog/fr/intlayer_with_vue-i18n.md +8 -4
- package/blog/hi/intlayer_with_i18next.md +8 -4
- package/blog/hi/intlayer_with_next-i18next.md +8 -4
- package/blog/hi/intlayer_with_next-intl.md +8 -4
- package/blog/hi/intlayer_with_react-i18next.md +8 -4
- package/blog/hi/intlayer_with_react-intl.md +8 -4
- package/blog/hi/intlayer_with_vue-i18n.md +8 -4
- package/blog/id/intlayer_with_i18next.md +8 -4
- package/blog/id/intlayer_with_next-i18next.md +8 -4
- package/blog/id/intlayer_with_next-intl.md +8 -4
- package/blog/id/intlayer_with_react-i18next.md +8 -4
- package/blog/id/intlayer_with_react-intl.md +8 -4
- package/blog/id/intlayer_with_vue-i18n.md +8 -4
- package/blog/it/intlayer_with_i18next.md +8 -4
- package/blog/it/intlayer_with_next-i18next.md +8 -4
- package/blog/it/intlayer_with_next-intl.md +8 -4
- package/blog/it/intlayer_with_react-i18next.md +8 -4
- package/blog/it/intlayer_with_react-intl.md +8 -4
- package/blog/it/intlayer_with_vue-i18n.md +8 -4
- package/blog/ja/intlayer_with_i18next.md +8 -4
- package/blog/ja/intlayer_with_next-i18next.md +8 -4
- package/blog/ja/intlayer_with_next-intl.md +8 -4
- package/blog/ja/intlayer_with_react-i18next.md +8 -4
- package/blog/ja/intlayer_with_react-intl.md +8 -4
- package/blog/ja/intlayer_with_vue-i18n.md +8 -4
- package/blog/ko/intlayer_with_i18next.md +8 -4
- package/blog/ko/intlayer_with_next-i18next.md +8 -4
- package/blog/ko/intlayer_with_next-intl.md +8 -4
- package/blog/ko/intlayer_with_react-i18next.md +8 -4
- package/blog/ko/intlayer_with_react-intl.md +8 -4
- package/blog/ko/intlayer_with_vue-i18n.md +8 -4
- package/blog/pl/intlayer_with_i18next.md +8 -4
- package/blog/pl/intlayer_with_next-i18next.md +8 -4
- package/blog/pl/intlayer_with_next-intl.md +8 -4
- package/blog/pl/intlayer_with_react-i18next.md +8 -4
- package/blog/pl/intlayer_with_react-intl.md +8 -4
- package/blog/pl/intlayer_with_vue-i18n.md +8 -4
- package/blog/pt/intlayer_with_i18next.md +8 -4
- package/blog/pt/intlayer_with_next-i18next.md +8 -4
- package/blog/pt/intlayer_with_next-intl.md +8 -4
- package/blog/pt/intlayer_with_react-i18next.md +8 -4
- package/blog/pt/intlayer_with_react-intl.md +8 -4
- package/blog/pt/intlayer_with_vue-i18n.md +8 -4
- package/blog/ru/intlayer_with_i18next.md +8 -4
- package/blog/ru/intlayer_with_next-i18next.md +8 -4
- package/blog/ru/intlayer_with_next-intl.md +8 -4
- package/blog/ru/intlayer_with_react-i18next.md +8 -4
- package/blog/ru/intlayer_with_react-intl.md +8 -4
- package/blog/ru/intlayer_with_vue-i18n.md +8 -4
- package/blog/tr/intlayer_with_i18next.md +8 -4
- package/blog/tr/intlayer_with_next-i18next.md +8 -4
- package/blog/tr/intlayer_with_next-intl.md +8 -4
- package/blog/tr/intlayer_with_react-i18next.md +8 -4
- package/blog/tr/intlayer_with_react-intl.md +8 -4
- package/blog/tr/intlayer_with_vue-i18n.md +8 -4
- package/blog/vi/intlayer_with_i18next.md +8 -4
- package/blog/vi/intlayer_with_next-i18next.md +8 -4
- package/blog/vi/intlayer_with_next-intl.md +8 -4
- package/blog/vi/intlayer_with_react-i18next.md +8 -4
- package/blog/vi/intlayer_with_react-intl.md +8 -4
- package/blog/vi/intlayer_with_vue-i18n.md +8 -4
- package/blog/zh/intlayer_with_i18next.md +8 -4
- package/blog/zh/intlayer_with_next-i18next.md +8 -4
- package/blog/zh/intlayer_with_next-intl.md +8 -4
- package/blog/zh/intlayer_with_react-i18next.md +8 -4
- package/blog/zh/intlayer_with_react-intl.md +8 -4
- package/blog/zh/intlayer_with_vue-i18n.md +8 -4
- package/docs/ar/cli/index.md +4 -0
- package/docs/ar/cli/sdk.md +4 -0
- package/docs/ar/intlayer_visual_editor.md +4 -0
- package/docs/ar/intlayer_with_angular.md +8 -0
- package/docs/ar/intlayer_with_create_react_app.md +8 -0
- package/docs/ar/intlayer_with_express.md +8 -0
- package/docs/ar/intlayer_with_lynx+react.md +8 -0
- package/docs/ar/intlayer_with_nestjs.md +8 -0
- package/docs/ar/intlayer_with_next-i18next.md +15 -3
- package/docs/ar/intlayer_with_next-intl.md +12 -3
- package/docs/ar/intlayer_with_nextjs_14.md +16 -0
- package/docs/ar/intlayer_with_nextjs_15.md +16 -0
- package/docs/ar/intlayer_with_nextjs_16.md +16 -0
- package/docs/ar/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/ar/intlayer_with_nuxt.md +9 -0
- package/docs/ar/intlayer_with_react_native+expo.md +9 -0
- package/docs/ar/intlayer_with_react_router_v7.md +86 -16
- package/docs/ar/intlayer_with_react_router_v7_fs_routes.md +16 -0
- package/docs/ar/intlayer_with_svelte_kit.md +8 -0
- package/docs/ar/intlayer_with_tanstack.md +14 -0
- package/docs/ar/intlayer_with_vite+preact.md +12 -2
- package/docs/ar/intlayer_with_vite+react.md +9 -0
- package/docs/ar/intlayer_with_vite+solid.md +9 -0
- package/docs/ar/intlayer_with_vite+svelte.md +7 -0
- package/docs/ar/intlayer_with_vite+vue.md +11 -0
- package/docs/de/cli/index.md +4 -0
- package/docs/de/cli/sdk.md +4 -0
- package/docs/de/intlayer_visual_editor.md +4 -0
- package/docs/de/intlayer_with_angular.md +8 -0
- package/docs/de/intlayer_with_create_react_app.md +8 -0
- package/docs/de/intlayer_with_express.md +8 -0
- package/docs/de/intlayer_with_lynx+react.md +8 -0
- package/docs/de/intlayer_with_nestjs.md +8 -0
- package/docs/de/intlayer_with_next-i18next.md +15 -3
- package/docs/de/intlayer_with_next-intl.md +12 -3
- package/docs/de/intlayer_with_nextjs_14.md +16 -0
- package/docs/de/intlayer_with_nextjs_15.md +16 -0
- package/docs/de/intlayer_with_nextjs_16.md +16 -0
- package/docs/de/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/de/intlayer_with_nuxt.md +9 -0
- package/docs/de/intlayer_with_react_native+expo.md +1 -0
- package/docs/de/intlayer_with_react_router_v7.md +86 -15
- package/docs/de/intlayer_with_react_router_v7_fs_routes.md +103 -19
- package/docs/de/intlayer_with_svelte_kit.md +8 -0
- package/docs/de/intlayer_with_tanstack.md +14 -0
- package/docs/de/intlayer_with_vite+preact.md +12 -2
- package/docs/de/intlayer_with_vite+react.md +9 -0
- package/docs/de/intlayer_with_vite+solid.md +9 -0
- package/docs/de/intlayer_with_vite+svelte.md +6 -0
- package/docs/de/intlayer_with_vite+vue.md +11 -0
- package/docs/en/cli/index.md +4 -0
- package/docs/en/cli/sdk.md +4 -0
- package/docs/en/configuration.md +1 -0
- package/docs/en/intlayer_visual_editor.md +4 -0
- package/docs/en/intlayer_with_angular.md +8 -0
- package/docs/en/intlayer_with_create_react_app.md +8 -0
- package/docs/en/intlayer_with_express.md +8 -0
- package/docs/en/intlayer_with_lynx+react.md +8 -0
- package/docs/en/intlayer_with_nestjs.md +8 -0
- package/docs/en/intlayer_with_next-i18next.md +15 -3
- package/docs/en/intlayer_with_next-intl.md +12 -3
- package/docs/en/intlayer_with_nextjs_14.md +16 -0
- package/docs/en/intlayer_with_nextjs_15.md +16 -0
- package/docs/en/intlayer_with_nextjs_16.md +16 -0
- package/docs/en/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/en/intlayer_with_nuxt.md +9 -0
- package/docs/en/intlayer_with_react_native+expo.md +9 -0
- package/docs/en/intlayer_with_react_router_v7.md +88 -15
- package/docs/en/intlayer_with_react_router_v7_fs_routes.md +106 -19
- package/docs/en/intlayer_with_svelte_kit.md +4 -0
- package/docs/en/intlayer_with_tanstack.md +14 -0
- package/docs/en/intlayer_with_vite+preact.md +11 -0
- package/docs/en/intlayer_with_vite+react.md +9 -0
- package/docs/en/intlayer_with_vite+solid.md +9 -0
- package/docs/en/intlayer_with_vite+svelte.md +7 -0
- package/docs/en/intlayer_with_vite+vue.md +11 -0
- package/docs/en-GB/cli/index.md +4 -0
- package/docs/en-GB/cli/sdk.md +4 -0
- package/docs/en-GB/configuration.md +1 -0
- package/docs/en-GB/intlayer_visual_editor.md +4 -0
- package/docs/en-GB/intlayer_with_angular.md +8 -0
- package/docs/en-GB/intlayer_with_create_react_app.md +16 -0
- package/docs/en-GB/intlayer_with_express.md +8 -0
- package/docs/en-GB/intlayer_with_lynx+react.md +16 -0
- package/docs/en-GB/intlayer_with_nestjs.md +8 -0
- package/docs/en-GB/intlayer_with_next-i18next.md +15 -3
- package/docs/en-GB/intlayer_with_next-intl.md +12 -3
- package/docs/en-GB/intlayer_with_nextjs_14.md +16 -0
- package/docs/en-GB/intlayer_with_nextjs_15.md +16 -0
- package/docs/en-GB/intlayer_with_nextjs_16.md +16 -0
- package/docs/en-GB/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/en-GB/intlayer_with_nuxt.md +9 -0
- package/docs/en-GB/intlayer_with_react_native+expo.md +9 -0
- package/docs/en-GB/intlayer_with_react_router_v7.md +87 -16
- package/docs/en-GB/intlayer_with_react_router_v7_fs_routes.md +16 -0
- package/docs/en-GB/intlayer_with_svelte_kit.md +8 -0
- package/docs/en-GB/intlayer_with_tanstack.md +14 -0
- package/docs/en-GB/intlayer_with_vite+preact.md +12 -2
- package/docs/en-GB/intlayer_with_vite+react.md +9 -0
- package/docs/en-GB/intlayer_with_vite+solid.md +9 -0
- package/docs/en-GB/intlayer_with_vite+svelte.md +7 -0
- package/docs/en-GB/intlayer_with_vite+vue.md +11 -0
- package/docs/es/cli/index.md +4 -0
- package/docs/es/cli/sdk.md +4 -0
- package/docs/es/intlayer_visual_editor.md +4 -0
- package/docs/es/intlayer_with_angular.md +8 -0
- package/docs/es/intlayer_with_create_react_app.md +8 -0
- package/docs/es/intlayer_with_express.md +8 -0
- package/docs/es/intlayer_with_lynx+react.md +8 -0
- package/docs/es/intlayer_with_nestjs.md +8 -0
- package/docs/es/intlayer_with_next-i18next.md +15 -3
- package/docs/es/intlayer_with_next-intl.md +12 -3
- package/docs/es/intlayer_with_nextjs_14.md +16 -0
- package/docs/es/intlayer_with_nextjs_15.md +16 -0
- package/docs/es/intlayer_with_nextjs_16.md +16 -0
- package/docs/es/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/es/intlayer_with_nuxt.md +9 -0
- package/docs/es/intlayer_with_react_native+expo.md +9 -0
- package/docs/es/intlayer_with_react_router_v7.md +86 -15
- package/docs/es/intlayer_with_react_router_v7_fs_routes.md +103 -19
- package/docs/es/intlayer_with_svelte_kit.md +8 -0
- package/docs/es/intlayer_with_tanstack.md +14 -0
- package/docs/es/intlayer_with_vite+preact.md +12 -2
- package/docs/es/intlayer_with_vite+react.md +9 -0
- package/docs/es/intlayer_with_vite+solid.md +9 -0
- package/docs/es/intlayer_with_vite+svelte.md +7 -0
- package/docs/es/intlayer_with_vite+vue.md +11 -0
- package/docs/es/packages/next-intlayer/index.md +5 -0
- package/docs/es/packages/react-intlayer/index.md +5 -0
- package/docs/fr/cli/index.md +4 -0
- package/docs/fr/cli/sdk.md +4 -0
- package/docs/fr/intlayer_visual_editor.md +4 -0
- package/docs/fr/intlayer_with_angular.md +8 -0
- package/docs/fr/intlayer_with_create_react_app.md +8 -0
- package/docs/fr/intlayer_with_express.md +8 -0
- package/docs/fr/intlayer_with_lynx+react.md +8 -0
- package/docs/fr/intlayer_with_nestjs.md +8 -0
- package/docs/fr/intlayer_with_next-i18next.md +15 -3
- package/docs/fr/intlayer_with_next-intl.md +12 -3
- package/docs/fr/intlayer_with_nextjs_14.md +16 -0
- package/docs/fr/intlayer_with_nextjs_15.md +16 -0
- package/docs/fr/intlayer_with_nextjs_16.md +16 -0
- package/docs/fr/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/fr/intlayer_with_nuxt.md +9 -0
- package/docs/fr/intlayer_with_react_native+expo.md +1 -0
- package/docs/fr/intlayer_with_react_router_v7.md +86 -15
- package/docs/fr/intlayer_with_react_router_v7_fs_routes.md +103 -19
- package/docs/fr/intlayer_with_svelte_kit.md +8 -0
- package/docs/fr/intlayer_with_tanstack.md +14 -0
- package/docs/fr/intlayer_with_vite+preact.md +12 -2
- package/docs/fr/intlayer_with_vite+react.md +9 -0
- package/docs/fr/intlayer_with_vite+solid.md +9 -0
- package/docs/fr/intlayer_with_vite+svelte.md +7 -0
- package/docs/fr/intlayer_with_vite+vue.md +11 -0
- package/docs/fr/packages/react-intlayer/index.md +5 -0
- package/docs/hi/cli/index.md +4 -0
- package/docs/hi/cli/sdk.md +4 -0
- package/docs/hi/intlayer_visual_editor.md +4 -0
- package/docs/hi/intlayer_with_angular.md +8 -0
- package/docs/hi/intlayer_with_create_react_app.md +8 -0
- package/docs/hi/intlayer_with_express.md +8 -0
- package/docs/hi/intlayer_with_lynx+react.md +8 -0
- package/docs/hi/intlayer_with_nestjs.md +8 -0
- package/docs/hi/intlayer_with_next-i18next.md +15 -3
- package/docs/hi/intlayer_with_next-intl.md +12 -3
- package/docs/hi/intlayer_with_nextjs_14.md +16 -0
- package/docs/hi/intlayer_with_nextjs_15.md +16 -0
- package/docs/hi/intlayer_with_nextjs_16.md +16 -0
- package/docs/hi/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/hi/intlayer_with_nuxt.md +9 -0
- package/docs/hi/intlayer_with_react_native+expo.md +1 -0
- package/docs/hi/intlayer_with_react_router_v7.md +86 -16
- package/docs/hi/intlayer_with_react_router_v7_fs_routes.md +16 -0
- package/docs/hi/intlayer_with_svelte_kit.md +8 -0
- package/docs/hi/intlayer_with_tanstack.md +14 -0
- package/docs/hi/intlayer_with_vite+preact.md +12 -2
- package/docs/hi/intlayer_with_vite+react.md +9 -0
- package/docs/hi/intlayer_with_vite+solid.md +9 -0
- package/docs/hi/intlayer_with_vite+svelte.md +7 -0
- package/docs/hi/intlayer_with_vite+vue.md +11 -0
- package/docs/hi/packages/intlayer/index.md +8 -0
- package/docs/id/cli/index.md +4 -0
- package/docs/id/cli/sdk.md +4 -0
- package/docs/id/intlayer_visual_editor.md +4 -0
- package/docs/id/intlayer_with_angular.md +8 -0
- package/docs/id/intlayer_with_create_react_app.md +8 -0
- package/docs/id/intlayer_with_express.md +8 -0
- package/docs/id/intlayer_with_lynx+react.md +8 -0
- package/docs/id/intlayer_with_nestjs.md +8 -0
- package/docs/id/intlayer_with_next-i18next.md +15 -3
- package/docs/id/intlayer_with_next-intl.md +12 -3
- package/docs/id/intlayer_with_nextjs_14.md +16 -0
- package/docs/id/intlayer_with_nextjs_15.md +16 -0
- package/docs/id/intlayer_with_nextjs_16.md +16 -0
- package/docs/id/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/id/intlayer_with_nuxt.md +9 -0
- package/docs/id/intlayer_with_react_native+expo.md +9 -0
- package/docs/id/intlayer_with_react_router_v7.md +86 -15
- package/docs/id/intlayer_with_react_router_v7_fs_routes.md +16 -0
- package/docs/id/intlayer_with_svelte_kit.md +8 -0
- package/docs/id/intlayer_with_tanstack.md +14 -0
- package/docs/id/intlayer_with_vite+preact.md +11 -0
- package/docs/id/intlayer_with_vite+react.md +9 -0
- package/docs/id/intlayer_with_vite+solid.md +9 -0
- package/docs/id/intlayer_with_vite+svelte.md +7 -0
- package/docs/id/intlayer_with_vite+vue.md +11 -0
- package/docs/it/cli/index.md +4 -0
- package/docs/it/cli/sdk.md +4 -0
- package/docs/it/intlayer_visual_editor.md +4 -0
- package/docs/it/intlayer_with_angular.md +8 -0
- package/docs/it/intlayer_with_create_react_app.md +8 -0
- package/docs/it/intlayer_with_express.md +8 -0
- package/docs/it/intlayer_with_lynx+react.md +8 -0
- package/docs/it/intlayer_with_nestjs.md +8 -0
- package/docs/it/intlayer_with_next-i18next.md +15 -3
- package/docs/it/intlayer_with_next-intl.md +12 -3
- package/docs/it/intlayer_with_nextjs_14.md +16 -0
- package/docs/it/intlayer_with_nextjs_15.md +16 -0
- package/docs/it/intlayer_with_nextjs_16.md +16 -0
- package/docs/it/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/it/intlayer_with_nuxt.md +9 -0
- package/docs/it/intlayer_with_react_native+expo.md +9 -0
- package/docs/it/intlayer_with_react_router_v7.md +86 -15
- package/docs/it/intlayer_with_react_router_v7_fs_routes.md +103 -19
- package/docs/it/intlayer_with_svelte_kit.md +8 -0
- package/docs/it/intlayer_with_tanstack.md +14 -0
- package/docs/it/intlayer_with_vite+preact.md +12 -2
- package/docs/it/intlayer_with_vite+react.md +9 -0
- package/docs/it/intlayer_with_vite+solid.md +9 -0
- package/docs/it/intlayer_with_vite+svelte.md +7 -0
- package/docs/it/intlayer_with_vite+vue.md +11 -0
- package/docs/ja/cli/index.md +4 -0
- package/docs/ja/cli/sdk.md +4 -0
- package/docs/ja/intlayer_visual_editor.md +4 -0
- package/docs/ja/intlayer_with_angular.md +8 -0
- package/docs/ja/intlayer_with_create_react_app.md +8 -0
- package/docs/ja/intlayer_with_express.md +8 -0
- package/docs/ja/intlayer_with_lynx+react.md +8 -0
- package/docs/ja/intlayer_with_nestjs.md +8 -0
- package/docs/ja/intlayer_with_next-i18next.md +15 -3
- package/docs/ja/intlayer_with_next-intl.md +12 -3
- package/docs/ja/intlayer_with_nextjs_14.md +16 -0
- package/docs/ja/intlayer_with_nextjs_15.md +16 -0
- package/docs/ja/intlayer_with_nextjs_16.md +16 -0
- package/docs/ja/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/ja/intlayer_with_nuxt.md +9 -0
- package/docs/ja/intlayer_with_react_native+expo.md +1 -0
- package/docs/ja/intlayer_with_react_router_v7.md +86 -15
- package/docs/ja/intlayer_with_react_router_v7_fs_routes.md +103 -19
- package/docs/ja/intlayer_with_svelte_kit.md +8 -0
- package/docs/ja/intlayer_with_tanstack.md +14 -0
- package/docs/ja/intlayer_with_vite+preact.md +12 -2
- package/docs/ja/intlayer_with_vite+react.md +9 -0
- package/docs/ja/intlayer_with_vite+solid.md +9 -0
- package/docs/ja/intlayer_with_vite+svelte.md +7 -0
- package/docs/ja/intlayer_with_vite+vue.md +11 -0
- package/docs/ko/cli/index.md +4 -0
- package/docs/ko/cli/sdk.md +4 -0
- package/docs/ko/intlayer_visual_editor.md +4 -0
- package/docs/ko/intlayer_with_angular.md +8 -0
- package/docs/ko/intlayer_with_create_react_app.md +8 -0
- package/docs/ko/intlayer_with_express.md +8 -0
- package/docs/ko/intlayer_with_lynx+react.md +8 -0
- package/docs/ko/intlayer_with_nestjs.md +8 -0
- package/docs/ko/intlayer_with_next-i18next.md +15 -3
- package/docs/ko/intlayer_with_next-intl.md +12 -3
- package/docs/ko/intlayer_with_nextjs_14.md +13 -0
- package/docs/ko/intlayer_with_nextjs_15.md +16 -0
- package/docs/ko/intlayer_with_nextjs_16.md +16 -0
- package/docs/ko/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/ko/intlayer_with_nuxt.md +9 -0
- package/docs/ko/intlayer_with_react_native+expo.md +9 -0
- package/docs/ko/intlayer_with_react_router_v7.md +86 -15
- package/docs/ko/intlayer_with_react_router_v7_fs_routes.md +16 -0
- package/docs/ko/intlayer_with_svelte_kit.md +8 -0
- package/docs/ko/intlayer_with_tanstack.md +14 -0
- package/docs/ko/intlayer_with_vite+preact.md +12 -2
- package/docs/ko/intlayer_with_vite+react.md +9 -0
- package/docs/ko/intlayer_with_vite+solid.md +9 -0
- package/docs/ko/intlayer_with_vite+svelte.md +7 -0
- package/docs/ko/intlayer_with_vite+vue.md +11 -0
- package/docs/pl/cli/index.md +4 -0
- package/docs/pl/cli/sdk.md +4 -0
- package/docs/pl/intlayer_visual_editor.md +4 -0
- package/docs/pl/intlayer_with_angular.md +8 -0
- package/docs/pl/intlayer_with_create_react_app.md +8 -0
- package/docs/pl/intlayer_with_express.md +8 -0
- package/docs/pl/intlayer_with_lynx+react.md +8 -0
- package/docs/pl/intlayer_with_nestjs.md +8 -0
- package/docs/pl/intlayer_with_next-i18next.md +15 -3
- package/docs/pl/intlayer_with_next-intl.md +12 -3
- package/docs/pl/intlayer_with_nextjs_14.md +16 -0
- package/docs/pl/intlayer_with_nextjs_15.md +16 -0
- package/docs/pl/intlayer_with_nextjs_16.md +16 -0
- package/docs/pl/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/pl/intlayer_with_nuxt.md +9 -0
- package/docs/pl/intlayer_with_react_native+expo.md +9 -0
- package/docs/pl/intlayer_with_react_router_v7.md +59 -13
- package/docs/pl/intlayer_with_react_router_v7_fs_routes.md +102 -18
- package/docs/pl/intlayer_with_svelte_kit.md +8 -0
- package/docs/pl/intlayer_with_tanstack.md +14 -0
- package/docs/pl/intlayer_with_vite+preact.md +11 -0
- package/docs/pl/intlayer_with_vite+react.md +9 -0
- package/docs/pl/intlayer_with_vite+solid.md +9 -0
- package/docs/pl/intlayer_with_vite+svelte.md +7 -0
- package/docs/pl/intlayer_with_vite+vue.md +11 -0
- package/docs/pt/cli/index.md +4 -0
- package/docs/pt/cli/sdk.md +4 -0
- package/docs/pt/intlayer_visual_editor.md +4 -0
- package/docs/pt/intlayer_with_angular.md +8 -0
- package/docs/pt/intlayer_with_create_react_app.md +8 -0
- package/docs/pt/intlayer_with_express.md +8 -0
- package/docs/pt/intlayer_with_lynx+react.md +8 -0
- package/docs/pt/intlayer_with_nestjs.md +8 -0
- package/docs/pt/intlayer_with_next-i18next.md +15 -3
- package/docs/pt/intlayer_with_next-intl.md +12 -3
- package/docs/pt/intlayer_with_nextjs_14.md +16 -0
- package/docs/pt/intlayer_with_nextjs_15.md +16 -0
- package/docs/pt/intlayer_with_nextjs_16.md +16 -0
- package/docs/pt/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/pt/intlayer_with_nuxt.md +9 -0
- package/docs/pt/intlayer_with_react_native+expo.md +9 -0
- package/docs/pt/intlayer_with_react_router_v7.md +93 -46
- package/docs/pt/intlayer_with_react_router_v7_fs_routes.md +103 -19
- package/docs/pt/intlayer_with_svelte_kit.md +8 -0
- package/docs/pt/intlayer_with_tanstack.md +14 -0
- package/docs/pt/intlayer_with_vite+preact.md +12 -2
- package/docs/pt/intlayer_with_vite+react.md +9 -0
- package/docs/pt/intlayer_with_vite+solid.md +9 -0
- package/docs/pt/intlayer_with_vite+svelte.md +7 -0
- package/docs/pt/intlayer_with_vite+vue.md +11 -0
- package/docs/ru/cli/index.md +4 -0
- package/docs/ru/cli/sdk.md +4 -0
- package/docs/ru/intlayer_visual_editor.md +4 -0
- package/docs/ru/intlayer_with_angular.md +8 -0
- package/docs/ru/intlayer_with_create_react_app.md +8 -0
- package/docs/ru/intlayer_with_express.md +8 -0
- package/docs/ru/intlayer_with_lynx+react.md +8 -0
- package/docs/ru/intlayer_with_nestjs.md +8 -0
- package/docs/ru/intlayer_with_next-i18next.md +15 -3
- package/docs/ru/intlayer_with_next-intl.md +12 -3
- package/docs/ru/intlayer_with_nextjs_14.md +16 -0
- package/docs/ru/intlayer_with_nextjs_15.md +16 -0
- package/docs/ru/intlayer_with_nextjs_16.md +16 -0
- package/docs/ru/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/ru/intlayer_with_nuxt.md +9 -0
- package/docs/ru/intlayer_with_react_native+expo.md +9 -0
- package/docs/ru/intlayer_with_react_router_v7.md +86 -15
- package/docs/ru/intlayer_with_react_router_v7_fs_routes.md +103 -19
- package/docs/ru/intlayer_with_svelte_kit.md +8 -0
- package/docs/ru/intlayer_with_tanstack.md +14 -0
- package/docs/ru/intlayer_with_vite+preact.md +12 -2
- package/docs/ru/intlayer_with_vite+react.md +9 -0
- package/docs/ru/intlayer_with_vite+solid.md +9 -0
- package/docs/ru/intlayer_with_vite+svelte.md +7 -0
- package/docs/ru/intlayer_with_vite+vue.md +11 -0
- package/docs/tr/cli/index.md +4 -0
- package/docs/tr/cli/sdk.md +4 -0
- package/docs/tr/intlayer_visual_editor.md +4 -0
- package/docs/tr/intlayer_with_angular.md +8 -0
- package/docs/tr/intlayer_with_create_react_app.md +8 -0
- package/docs/tr/intlayer_with_express.md +8 -0
- package/docs/tr/intlayer_with_lynx+react.md +8 -0
- package/docs/tr/intlayer_with_nestjs.md +8 -0
- package/docs/tr/intlayer_with_next-i18next.md +15 -3
- package/docs/tr/intlayer_with_next-intl.md +12 -3
- package/docs/tr/intlayer_with_nextjs_14.md +16 -0
- package/docs/tr/intlayer_with_nextjs_15.md +16 -0
- package/docs/tr/intlayer_with_nextjs_16.md +16 -0
- package/docs/tr/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/tr/intlayer_with_nuxt.md +9 -0
- package/docs/tr/intlayer_with_react_native+expo.md +9 -0
- package/docs/tr/intlayer_with_react_router_v7.md +86 -15
- package/docs/tr/intlayer_with_react_router_v7_fs_routes.md +103 -19
- package/docs/tr/intlayer_with_svelte_kit.md +8 -0
- package/docs/tr/intlayer_with_tanstack.md +14 -0
- package/docs/tr/intlayer_with_vite+preact.md +12 -2
- package/docs/tr/intlayer_with_vite+react.md +9 -0
- package/docs/tr/intlayer_with_vite+solid.md +9 -0
- package/docs/tr/intlayer_with_vite+svelte.md +7 -0
- package/docs/tr/intlayer_with_vite+vue.md +11 -0
- package/docs/vi/cli/index.md +5 -0
- package/docs/vi/cli/sdk.md +4 -0
- package/docs/vi/intlayer_visual_editor.md +4 -0
- package/docs/vi/intlayer_with_angular.md +8 -0
- package/docs/vi/intlayer_with_create_react_app.md +8 -0
- package/docs/vi/intlayer_with_express.md +8 -0
- package/docs/vi/intlayer_with_lynx+react.md +8 -0
- package/docs/vi/intlayer_with_nestjs.md +8 -0
- package/docs/vi/intlayer_with_next-i18next.md +15 -3
- package/docs/vi/intlayer_with_next-intl.md +12 -3
- package/docs/vi/intlayer_with_nextjs_14.md +16 -0
- package/docs/vi/intlayer_with_nextjs_15.md +16 -0
- package/docs/vi/intlayer_with_nextjs_16.md +16 -0
- package/docs/vi/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/vi/intlayer_with_nuxt.md +9 -0
- package/docs/vi/intlayer_with_react_native+expo.md +9 -0
- package/docs/vi/intlayer_with_react_router_v7.md +86 -15
- package/docs/vi/intlayer_with_react_router_v7_fs_routes.md +16 -0
- package/docs/vi/intlayer_with_svelte_kit.md +8 -0
- package/docs/vi/intlayer_with_tanstack.md +14 -0
- package/docs/vi/intlayer_with_vite+preact.md +11 -0
- package/docs/vi/intlayer_with_vite+react.md +9 -0
- package/docs/vi/intlayer_with_vite+solid.md +9 -0
- package/docs/vi/intlayer_with_vite+svelte.md +7 -0
- package/docs/vi/intlayer_with_vite+vue.md +11 -0
- package/docs/zh/cli/index.md +4 -0
- package/docs/zh/cli/sdk.md +4 -0
- package/docs/zh/intlayer_visual_editor.md +4 -0
- package/docs/zh/intlayer_with_angular.md +8 -0
- package/docs/zh/intlayer_with_create_react_app.md +8 -0
- package/docs/zh/intlayer_with_express.md +8 -0
- package/docs/zh/intlayer_with_lynx+react.md +8 -0
- package/docs/zh/intlayer_with_nestjs.md +8 -0
- package/docs/zh/intlayer_with_next-i18next.md +15 -3
- package/docs/zh/intlayer_with_next-intl.md +12 -3
- package/docs/zh/intlayer_with_nextjs_14.md +16 -0
- package/docs/zh/intlayer_with_nextjs_15.md +16 -0
- package/docs/zh/intlayer_with_nextjs_16.md +16 -0
- package/docs/zh/intlayer_with_nextjs_page_router.md +16 -0
- package/docs/zh/intlayer_with_nuxt.md +9 -0
- package/docs/zh/intlayer_with_react_native+expo.md +9 -0
- package/docs/zh/intlayer_with_react_router_v7.md +86 -15
- package/docs/zh/intlayer_with_react_router_v7_fs_routes.md +16 -0
- package/docs/zh/intlayer_with_svelte_kit.md +8 -0
- package/docs/zh/intlayer_with_tanstack.md +14 -0
- package/docs/zh/intlayer_with_vite+preact.md +12 -2
- package/docs/zh/intlayer_with_vite+react.md +9 -0
- package/docs/zh/intlayer_with_vite+solid.md +9 -0
- package/docs/zh/intlayer_with_vite+svelte.md +7 -0
- package/docs/zh/intlayer_with_vite+vue.md +11 -0
- package/package.json +6 -6
|
@@ -47,14 +47,22 @@ Installa i pacchetti necessari usando il tuo gestore di pacchetti preferito:
|
|
|
47
47
|
|
|
48
48
|
```bash packageManager="npm"
|
|
49
49
|
npm install intlayer next-intlayer
|
|
50
|
+
npx intlayer init
|
|
50
51
|
```
|
|
51
52
|
|
|
52
53
|
```bash packageManager="pnpm"
|
|
53
54
|
pnpm add intlayer next-intlayer
|
|
55
|
+
pnpm intlayer init
|
|
54
56
|
```
|
|
55
57
|
|
|
56
58
|
```bash packageManager="yarn"
|
|
57
59
|
yarn add intlayer next-intlayer
|
|
60
|
+
yarn intlayer init
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
```bash packageManager="bun"
|
|
64
|
+
bun add intlayer next-intlayer
|
|
65
|
+
bunx intlayer init
|
|
58
66
|
```
|
|
59
67
|
|
|
60
68
|
- **intlayer**
|
|
@@ -1416,14 +1424,22 @@ Per abilitare questa ottimizzazione, installa il pacchetto `@intlayer/swc`. Una
|
|
|
1416
1424
|
|
|
1417
1425
|
```bash packageManager="npm"
|
|
1418
1426
|
npm install @intlayer/swc --save-dev
|
|
1427
|
+
npx intlayer init
|
|
1419
1428
|
```
|
|
1420
1429
|
|
|
1421
1430
|
```bash packageManager="pnpm"
|
|
1422
1431
|
pnpm add @intlayer/swc --save-dev
|
|
1432
|
+
pnpm intlayer init
|
|
1423
1433
|
```
|
|
1424
1434
|
|
|
1425
1435
|
```bash packageManager="yarn"
|
|
1426
1436
|
yarn add @intlayer/swc --save-dev
|
|
1437
|
+
yarn intlayer init
|
|
1438
|
+
```
|
|
1439
|
+
|
|
1440
|
+
```bash packageManager="bun"
|
|
1441
|
+
bun add @intlayer/swc --dev
|
|
1442
|
+
bunx intlayer init
|
|
1427
1443
|
```
|
|
1428
1444
|
|
|
1429
1445
|
> Nota: Questa ottimizzazione è disponibile solo per Next.js 13 e versioni successive.
|
|
@@ -74,16 +74,25 @@ Installa i pacchetti necessari usando npm:
|
|
|
74
74
|
```bash packageManager="npm"
|
|
75
75
|
npm install intlayer vue-intlayer
|
|
76
76
|
npm install --save-dev nuxt-intlayer
|
|
77
|
+
npx intlayer init
|
|
77
78
|
```
|
|
78
79
|
|
|
79
80
|
```bash packageManager="pnpm"
|
|
80
81
|
pnpm add intlayer vue-intlayer
|
|
81
82
|
pnpm add --save-dev nuxt-intlayer
|
|
83
|
+
pnpm intlayer init
|
|
82
84
|
```
|
|
83
85
|
|
|
84
86
|
```bash packageManager="yarn"
|
|
85
87
|
yarn add intlayer vue-intlayer
|
|
86
88
|
yarn add --save-dev nuxt-intlayer
|
|
89
|
+
yarn intlayer init
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
```bash packageManager="bun"
|
|
93
|
+
bun add intlayer vue-intlayer
|
|
94
|
+
bun add --dev nuxt-intlayer
|
|
95
|
+
bunx intlayer init
|
|
87
96
|
```
|
|
88
97
|
|
|
89
98
|
- **intlayer**
|
|
@@ -45,16 +45,25 @@ Dal tuo progetto React Native, installa i seguenti pacchetti:
|
|
|
45
45
|
```bash packageManager="npm"
|
|
46
46
|
npm install intlayer react-intlayer
|
|
47
47
|
npm install --save-dev react-native-intlayer
|
|
48
|
+
npx intlayer init
|
|
48
49
|
```
|
|
49
50
|
|
|
50
51
|
```bash packageManager="pnpm"
|
|
51
52
|
pnpm add intlayer react-intlayer
|
|
52
53
|
pnpm add --save-dev react-native-intlayer
|
|
54
|
+
pnpm intlayer init
|
|
53
55
|
```
|
|
54
56
|
|
|
55
57
|
```bash packageManager="yarn"
|
|
56
58
|
yarn add intlayer react-intlayer
|
|
57
59
|
yarn add --save-dev react-native-intlayer
|
|
60
|
+
yarn intlayer init
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
```bash packageManager="bun"
|
|
64
|
+
bun add intlayer react-intlayer
|
|
65
|
+
bun add --dev react-native-intlayer
|
|
66
|
+
bunx intlayer init
|
|
58
67
|
```
|
|
59
68
|
|
|
60
69
|
### Pacchetti
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
createdAt: 2025-09-04
|
|
3
|
-
updatedAt: 2025-
|
|
3
|
+
updatedAt: 2025-12-27
|
|
4
4
|
title: Come tradurre la tua React Router v7 – guida i18n 2025
|
|
5
5
|
description: Scopri come aggiungere l'internazionalizzazione (i18n) alla tua applicazione React Router v7 utilizzando Intlayer. Segui questa guida completa per rendere la tua app multilingue con il routing consapevole della localizzazione.
|
|
6
6
|
keywords:
|
|
@@ -20,6 +20,9 @@ slugs:
|
|
|
20
20
|
applicationTemplate: https://github.com/aymericzip/intlayer-react-router-v7-template
|
|
21
21
|
youtubeVideo: https://www.youtube.com/watch?v=dS9L7uJeak4
|
|
22
22
|
history:
|
|
23
|
+
- version: 7.5.6
|
|
24
|
+
date: 2025-12-27
|
|
25
|
+
changes: Aggiorna Layout e gestisci 404
|
|
23
26
|
- version: 6.1.5
|
|
24
27
|
date: 2025-10-03
|
|
25
28
|
changes: Documentazione aggiornata
|
|
@@ -59,11 +62,25 @@ Installa i pacchetti necessari usando il tuo gestore di pacchetti preferito:
|
|
|
59
62
|
```bash packageManager="npm"
|
|
60
63
|
npm install intlayer react-intlayer
|
|
61
64
|
npm install vite-intlayer --save-dev
|
|
65
|
+
npx intlayer init
|
|
62
66
|
```
|
|
63
67
|
|
|
64
68
|
```bash packageManager="pnpm"
|
|
65
69
|
pnpm add intlayer react-intlayer
|
|
66
70
|
pnpm add vite-intlayer --save-dev
|
|
71
|
+
pnpm intlayer init
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
```bash packageManager="yarn"
|
|
75
|
+
yarn add intlayer react-intlayer
|
|
76
|
+
yarn add vite-intlayer --save-dev
|
|
77
|
+
yarn intlayer init
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
```bash packageManager="bun"
|
|
81
|
+
bun add intlayer react-intlayer
|
|
82
|
+
bun add vite-intlayer --dev
|
|
83
|
+
bunx intlayer init
|
|
67
84
|
```
|
|
68
85
|
|
|
69
86
|
- **intlayer**
|
|
@@ -173,10 +190,8 @@ Configura la tua configurazione di routing con rotte consapevoli della localizza
|
|
|
173
190
|
import { layout, route, type RouteConfig } from "@react-router/dev/routes";
|
|
174
191
|
|
|
175
192
|
export default [
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
route("/:lang?/about", "routes/about/page.tsx"), // Pagina "about" localizzata
|
|
179
|
-
]),
|
|
193
|
+
route("/:lang?", "routes/page.tsx"), // Pagina iniziale localizzata
|
|
194
|
+
route("/:lang?/about", "routes/about/page.tsx"), // Pagina "about" localizzata
|
|
180
195
|
] satisfies RouteConfig;
|
|
181
196
|
```
|
|
182
197
|
|
|
@@ -186,19 +201,50 @@ Configura il layout principale e i layout specifici per la localizzazione:
|
|
|
186
201
|
|
|
187
202
|
#### Layout Principale
|
|
188
203
|
|
|
189
|
-
```tsx fileName="app/
|
|
204
|
+
```tsx fileName="app/root.tsx"
|
|
205
|
+
import { getLocaleFromPath } from "intlayer";
|
|
190
206
|
import { IntlayerProvider } from "react-intlayer";
|
|
191
|
-
import {
|
|
207
|
+
import {
|
|
208
|
+
data,
|
|
209
|
+
Meta,
|
|
210
|
+
Scripts,
|
|
211
|
+
ScrollRestoration,
|
|
212
|
+
useLoaderData,
|
|
213
|
+
} from "react-router";
|
|
214
|
+
import type { Route } from "./+types/root";
|
|
192
215
|
|
|
193
|
-
|
|
216
|
+
// ... Unchanged App, links and ErrorBoundary code
|
|
194
217
|
|
|
195
|
-
export
|
|
196
|
-
const
|
|
218
|
+
export async function loader({ request }: Route.LoaderArgs) {
|
|
219
|
+
const locale = getLocaleFromPath(request.url);
|
|
220
|
+
|
|
221
|
+
if (!locale) {
|
|
222
|
+
throw data("Language not supported", { status: 404 });
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
return { locale };
|
|
226
|
+
}
|
|
227
|
+
|
|
228
|
+
export function Layout({
|
|
229
|
+
children,
|
|
230
|
+
}: { children: React.ReactNode } & Route.ComponentProps) {
|
|
231
|
+
const data = useLoaderData<typeof loader>();
|
|
232
|
+
const { locale } = data ?? {};
|
|
197
233
|
|
|
198
234
|
return (
|
|
199
|
-
<
|
|
200
|
-
<
|
|
201
|
-
|
|
235
|
+
<html lang={locale}>
|
|
236
|
+
<head>
|
|
237
|
+
<meta charSet="utf-8" />
|
|
238
|
+
<meta content="width=device-width, initial-scale=1" name="viewport" />
|
|
239
|
+
<Meta />
|
|
240
|
+
<Links />
|
|
241
|
+
</head>
|
|
242
|
+
<body>
|
|
243
|
+
<IntlayerProvider locale={locale}>{children}</IntlayerProvider>
|
|
244
|
+
<ScrollRestoration />
|
|
245
|
+
<Scripts />
|
|
246
|
+
</body>
|
|
247
|
+
</html>
|
|
202
248
|
);
|
|
203
249
|
}
|
|
204
250
|
```
|
|
@@ -312,9 +358,34 @@ Accedi ai tuoi dizionari di contenuti in tutta l'applicazione:
|
|
|
312
358
|
|
|
313
359
|
#### Pagina Home Localizzata
|
|
314
360
|
|
|
315
|
-
```tsx fileName="app/routes/
|
|
361
|
+
```tsx fileName="app/routes/page.tsx"
|
|
362
|
+
import { getIntlayer, validatePrefix } from "intlayer";
|
|
316
363
|
import { useIntlayer } from "react-intlayer";
|
|
317
|
-
import {
|
|
364
|
+
import { data } from "react-router";
|
|
365
|
+
|
|
366
|
+
import { LocaleSwitcher } from "~/components/locale-switcher";
|
|
367
|
+
|
|
368
|
+
import { Navbar } from "~/components/navbar";
|
|
369
|
+
import type { Route } from "./+types/page";
|
|
370
|
+
|
|
371
|
+
export const loader = ({ params }: Route.LoaderArgs) => {
|
|
372
|
+
const { locale } = params;
|
|
373
|
+
|
|
374
|
+
const { isValid } = validatePrefix(locale);
|
|
375
|
+
|
|
376
|
+
if (!isValid) {
|
|
377
|
+
throw data("Locale not supported", { status: 404 });
|
|
378
|
+
}
|
|
379
|
+
};
|
|
380
|
+
|
|
381
|
+
export const meta: Route.MetaFunction = ({ params }) => {
|
|
382
|
+
const content = getIntlayer("page", params.locale);
|
|
383
|
+
|
|
384
|
+
return [
|
|
385
|
+
{ title: content.title },
|
|
386
|
+
{ content: content.description, name: "description" },
|
|
387
|
+
];
|
|
388
|
+
};
|
|
318
389
|
|
|
319
390
|
export default function Page() {
|
|
320
391
|
const { title, description, aboutLink } = useIntlayer("page");
|
|
@@ -31,6 +31,8 @@ history:
|
|
|
31
31
|
|
|
32
32
|
Questa guida dimostra come integrare **Intlayer** per un'internazionalizzazione senza soluzione di continuità nei progetti React Router v7 usando **routing basato sul file system** (`@react-router/fs-routes`) con routing consapevole della localizzazione, supporto TypeScript e pratiche di sviluppo moderne.
|
|
33
33
|
|
|
34
|
+
Per il routing lato client, fare riferimento alla guida [Intlayer con React Router v7](https://github.com/aymericzip/intlayer/blob/main/docs/docs/it/intlayer_with_react_router_v7.md).
|
|
35
|
+
|
|
34
36
|
## Table of Contents
|
|
35
37
|
|
|
36
38
|
<TOC/>
|
|
@@ -80,6 +82,7 @@ Installa i pacchetti necessari usando il tuo gestore di pacchetti preferito:
|
|
|
80
82
|
npm install intlayer react-intlayer
|
|
81
83
|
npm install vite-intlayer --save-dev
|
|
82
84
|
npm install @react-router/fs-routes --save-dev
|
|
85
|
+
npx intlayer init
|
|
83
86
|
```
|
|
84
87
|
|
|
85
88
|
```bash packageManager="pnpm"
|
|
@@ -88,6 +91,13 @@ pnpm add vite-intlayer --save-dev
|
|
|
88
91
|
pnpm add @react-router/fs-routes --save-dev
|
|
89
92
|
```
|
|
90
93
|
|
|
94
|
+
```bash packageManager="bun"
|
|
95
|
+
bun add intlayer react-intlayer
|
|
96
|
+
bun add vite-intlayer --dev
|
|
97
|
+
bun add @react-router/fs-routes --dev
|
|
98
|
+
bunx intlayer init
|
|
99
|
+
```
|
|
100
|
+
|
|
91
101
|
- **intlayer**
|
|
92
102
|
|
|
93
103
|
- **Il pacchetto core** che fornisce strumenti di internazionalizzazione per la gestione della configurazione, la traduzione, la [dichiarazione dei contenuti](https://github.com/aymericzip/intlayer/blob/main/docs/docs/it/dictionary/get_started.md), la traspilazione e i [comandi CLI](https://github.com/aymericzip/intlayer/blob/main/docs/docs/it/intlayer_cli.md).
|
|
@@ -197,12 +207,13 @@ Crea i seguenti file nella directory `app/routes/`:
|
|
|
197
207
|
#### Struttura dei file
|
|
198
208
|
|
|
199
209
|
```bash
|
|
200
|
-
app/
|
|
201
|
-
├──
|
|
202
|
-
|
|
203
|
-
├── ($locale)._index.
|
|
204
|
-
├── ($locale).
|
|
205
|
-
|
|
210
|
+
app/
|
|
211
|
+
├── root.tsx # Wrapper di layout per le rotte di locale
|
|
212
|
+
└──routes/
|
|
213
|
+
├── ($locale)._index.tsx # Pagina iniziale (/, /es, ecc.)
|
|
214
|
+
├── ($locale)._index.content.ts # Contenuto della pagina iniziale
|
|
215
|
+
├── ($locale).about.tsx # Pagina About (/about, /es/about, ecc.)
|
|
216
|
+
└── ($locale).about.content.ts # Contenuto della pagina About
|
|
206
217
|
```
|
|
207
218
|
|
|
208
219
|
Le convenzioni di denominazione:
|
|
@@ -214,23 +225,50 @@ Le convenzioni di denominazione:
|
|
|
214
225
|
|
|
215
226
|
#### Componente Layout
|
|
216
227
|
|
|
217
|
-
```tsx fileName="app/
|
|
228
|
+
```tsx fileName="app/root.tsx"
|
|
229
|
+
import { getLocaleFromPath } from "intlayer";
|
|
218
230
|
import { IntlayerProvider } from "react-intlayer";
|
|
219
|
-
import {
|
|
231
|
+
import {
|
|
232
|
+
isRouteErrorResponse,
|
|
233
|
+
Meta,
|
|
234
|
+
Outlet,
|
|
235
|
+
Scripts,
|
|
236
|
+
ScrollRestoration,
|
|
237
|
+
useLoaderData,
|
|
238
|
+
} from "react-router";
|
|
220
239
|
|
|
221
|
-
import {
|
|
240
|
+
import type { Route } from "./+types/root";
|
|
222
241
|
|
|
223
|
-
import
|
|
242
|
+
import "./app.css";
|
|
224
243
|
|
|
225
|
-
|
|
226
|
-
useI18nHTMLAttributes();
|
|
244
|
+
// links and ErrorBoundary code
|
|
227
245
|
|
|
228
|
-
|
|
246
|
+
export async function loader({ request }: Route.LoaderArgs) {
|
|
247
|
+
const locale = getLocaleFromPath(request.url);
|
|
248
|
+
|
|
249
|
+
return { locale };
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
export function Layout({
|
|
253
|
+
children,
|
|
254
|
+
}: { children: React.ReactNode } & Route.ComponentProps) {
|
|
255
|
+
const data = useLoaderData<typeof loader>();
|
|
256
|
+
const { locale } = data ?? {};
|
|
229
257
|
|
|
230
258
|
return (
|
|
231
|
-
<
|
|
232
|
-
<
|
|
233
|
-
|
|
259
|
+
<html lang={locale}>
|
|
260
|
+
<head>
|
|
261
|
+
<meta charSet="utf-8" />
|
|
262
|
+
<meta content="width=device-width, initial-scale=1" name="viewport" />
|
|
263
|
+
<Meta />
|
|
264
|
+
<Links />
|
|
265
|
+
</head>
|
|
266
|
+
<body>
|
|
267
|
+
<IntlayerProvider locale={locale}>{children}</IntlayerProvider>
|
|
268
|
+
<ScrollRestoration />
|
|
269
|
+
<Scripts />
|
|
270
|
+
</body>
|
|
271
|
+
</html>
|
|
234
272
|
);
|
|
235
273
|
}
|
|
236
274
|
```
|
|
@@ -238,11 +276,34 @@ export default function RootLayout({ params }: Route.ComponentProps) {
|
|
|
238
276
|
#### Pagina Indice
|
|
239
277
|
|
|
240
278
|
```tsx fileName="app/routes/($locale)._index.tsx"
|
|
279
|
+
import { getIntlayer, validatePrefix } from "intlayer";
|
|
241
280
|
import { useIntlayer } from "react-intlayer";
|
|
242
|
-
import {
|
|
281
|
+
import { data } from "react-router";
|
|
282
|
+
|
|
283
|
+
import { LocaleSwitcher } from "~/components/locale-switcher";
|
|
284
|
+
import { Navbar } from "~/components/navbar";
|
|
243
285
|
|
|
244
286
|
import type { Route } from "./+types/($locale)._index";
|
|
245
287
|
|
|
288
|
+
export const loader = ({ params }: Route.LoaderArgs) => {
|
|
289
|
+
const { locale } = params;
|
|
290
|
+
|
|
291
|
+
const { isValid } = validatePrefix(locale);
|
|
292
|
+
|
|
293
|
+
if (!isValid) {
|
|
294
|
+
throw data("Locale not supported", { status: 404 });
|
|
295
|
+
}
|
|
296
|
+
};
|
|
297
|
+
|
|
298
|
+
export const meta: Route.MetaFunction = ({ params }) => {
|
|
299
|
+
const content = getIntlayer("page", params.locale);
|
|
300
|
+
|
|
301
|
+
return [
|
|
302
|
+
{ title: content.title },
|
|
303
|
+
{ content: content.description, name: "description" },
|
|
304
|
+
];
|
|
305
|
+
};
|
|
306
|
+
|
|
246
307
|
export default function Page() {
|
|
247
308
|
const { title, description, aboutLink } = useIntlayer("page");
|
|
248
309
|
|
|
@@ -261,11 +322,34 @@ export default function Page() {
|
|
|
261
322
|
#### Pagina About
|
|
262
323
|
|
|
263
324
|
```tsx fileName="app/routes/($locale).about.tsx"
|
|
325
|
+
import { getIntlayer, validatePrefix } from "intlayer";
|
|
264
326
|
import { useIntlayer } from "react-intlayer";
|
|
265
|
-
import {
|
|
327
|
+
import { data } from "react-router";
|
|
328
|
+
|
|
329
|
+
import { LocaleSwitcher } from "~/components/locale-switcher";
|
|
330
|
+
import { Navbar } from "~/components/navbar";
|
|
266
331
|
|
|
267
332
|
import type { Route } from "./+types/($locale).about";
|
|
268
333
|
|
|
334
|
+
export const loader = ({ params }: Route.LoaderArgs) => {
|
|
335
|
+
const { locale } = params;
|
|
336
|
+
|
|
337
|
+
const { isValid } = validatePrefix(locale);
|
|
338
|
+
|
|
339
|
+
if (!isValid) {
|
|
340
|
+
throw data("Locale not supported", { status: 404 });
|
|
341
|
+
}
|
|
342
|
+
};
|
|
343
|
+
|
|
344
|
+
export const meta: Route.MetaFunction = ({ params }) => {
|
|
345
|
+
const content = getIntlayer("about", params.locale);
|
|
346
|
+
|
|
347
|
+
return [
|
|
348
|
+
{ title: content.title },
|
|
349
|
+
{ content: content.description, name: "description" },
|
|
350
|
+
];
|
|
351
|
+
};
|
|
352
|
+
|
|
269
353
|
export default function AboutPage() {
|
|
270
354
|
const { title, content, homeLink } = useIntlayer("about");
|
|
271
355
|
|
|
@@ -486,7 +570,7 @@ export const useI18nHTMLAttributes = () => {
|
|
|
486
570
|
};
|
|
487
571
|
```
|
|
488
572
|
|
|
489
|
-
Questo hook è già utilizzato nel componente di layout (`
|
|
573
|
+
Questo hook è già utilizzato nel componente di layout (`root.tsx`) mostrato nel Passo 5.
|
|
490
574
|
|
|
491
575
|
### Passo 10: Aggiungere il middleware (Opzionale)
|
|
492
576
|
|
|
@@ -99,21 +99,25 @@ Installa i pacchetti necessari usando npm:
|
|
|
99
99
|
```bash packageManager="npm"
|
|
100
100
|
npm install intlayer svelte-intlayer
|
|
101
101
|
npm install vite-intlayer --save-dev
|
|
102
|
+
npx intlayer init
|
|
102
103
|
```
|
|
103
104
|
|
|
104
105
|
```bash packageManager="pnpm"
|
|
105
106
|
pnpm add intlayer svelte-intlayer
|
|
106
107
|
pnpm add vite-intlayer --save-dev
|
|
108
|
+
pnpm intlayer init
|
|
107
109
|
```
|
|
108
110
|
|
|
109
111
|
```bash packageManager="yarn"
|
|
110
112
|
yarn add intlayer svelte-intlayer
|
|
111
113
|
yarn add vite-intlayer --save-dev
|
|
114
|
+
yarn intlayer init
|
|
112
115
|
```
|
|
113
116
|
|
|
114
117
|
```bash packageManager="bun"
|
|
115
118
|
bun add intlayer svelte-intlayer
|
|
116
119
|
bun add vite-intlayer --save-dev
|
|
120
|
+
bunx intlayer init
|
|
117
121
|
```
|
|
118
122
|
|
|
119
123
|
- **intlayer**: Il pacchetto core per l'internazionalizzazione (i18n).
|
|
@@ -271,21 +275,25 @@ Installa i pacchetti necessari usando npm:
|
|
|
271
275
|
```bash packageManager="npm"
|
|
272
276
|
npm install intlayer svelte-intlayer
|
|
273
277
|
npm install vite-intlayer --save-dev
|
|
278
|
+
npx intlayer init
|
|
274
279
|
```
|
|
275
280
|
|
|
276
281
|
```bash packageManager="pnpm"
|
|
277
282
|
pnpm add intlayer svelte-intlayer
|
|
278
283
|
pnpm add vite-intlayer --save-dev
|
|
284
|
+
pnpm intlayer init
|
|
279
285
|
```
|
|
280
286
|
|
|
281
287
|
```bash packageManager="yarn"
|
|
282
288
|
yarn add intlayer svelte-intlayer
|
|
283
289
|
yarn add vite-intlayer --save-dev
|
|
290
|
+
yarn intlayer init
|
|
284
291
|
```
|
|
285
292
|
|
|
286
293
|
```bash packageManager="bun"
|
|
287
294
|
bun add intlayer svelte-intlayer
|
|
288
295
|
bun add vite-intlayer --save-dev
|
|
296
|
+
bunx intlayer init
|
|
289
297
|
```
|
|
290
298
|
|
|
291
299
|
- **intlayer**: Il pacchetto core per l'internazionalizzazione (i18n).
|
|
@@ -89,11 +89,25 @@ Installa i pacchetti necessari utilizzando il tuo gestore di pacchetti preferito
|
|
|
89
89
|
```bash packageManager="npm"
|
|
90
90
|
npm install intlayer react-intlayer
|
|
91
91
|
npm install vite-intlayer --save-dev
|
|
92
|
+
npx intlayer init
|
|
92
93
|
```
|
|
93
94
|
|
|
94
95
|
```bash packageManager="pnpm"
|
|
95
96
|
pnpm add intlayer react-intlayer
|
|
96
97
|
pnpm add vite-intlayer --save-dev
|
|
98
|
+
pnpm intlayer init
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
```bash packageManager="yarn"
|
|
102
|
+
yarn add intlayer react-intlayer
|
|
103
|
+
yarn add vite-intlayer --save-dev
|
|
104
|
+
yarn intlayer init
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
```bash packageManager="bun"
|
|
108
|
+
bun add intlayer react-intlayer
|
|
109
|
+
bun add vite-intlayer --dev
|
|
110
|
+
bunx intlayer init
|
|
97
111
|
```
|
|
98
112
|
|
|
99
113
|
- **intlayer**
|
|
@@ -49,16 +49,25 @@ Installa i pacchetti necessari usando npm:
|
|
|
49
49
|
```bash packageManager="npm"
|
|
50
50
|
npm install intlayer preact-intlayer
|
|
51
51
|
npm install vite-intlayer --save-dev
|
|
52
|
+
npx intlayer init
|
|
52
53
|
```
|
|
53
54
|
|
|
54
55
|
```bash packageManager="pnpm"
|
|
55
56
|
pnpm add intlayer preact-intlayer
|
|
56
57
|
pnpm add vite-intlayer --save-dev
|
|
58
|
+
pnpm intlayer init
|
|
57
59
|
```
|
|
58
60
|
|
|
59
61
|
```bash packageManager="yarn"
|
|
60
62
|
yarn add intlayer preact-intlayer
|
|
61
63
|
yarn add vite-intlayer --save-dev
|
|
64
|
+
yarn intlayer init
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
```bash packageManager="bun"
|
|
68
|
+
bun add intlayer preact-intlayer
|
|
69
|
+
bun add vite-intlayer --dev
|
|
70
|
+
bunx intlayer init
|
|
62
71
|
```
|
|
63
72
|
|
|
64
73
|
- **intlayer**
|
|
@@ -634,10 +643,12 @@ Per prima cosa, installa `preact-iso`:
|
|
|
634
643
|
|
|
635
644
|
```bash packageManager="npm"
|
|
636
645
|
npm install preact-iso
|
|
646
|
+
npx intlayer init
|
|
637
647
|
```
|
|
638
648
|
|
|
639
649
|
```bash packageManager="pnpm"
|
|
640
650
|
pnpm add preact-iso
|
|
651
|
+
pnpm intlayer init
|
|
641
652
|
```
|
|
642
653
|
|
|
643
654
|
```bash packageManager="yarn"
|
|
@@ -1464,8 +1475,7 @@ import { useLocale, useLocation, route } from "preact-intlayer"; // Si assume ch
|
|
|
1464
1475
|
import type { JSX } from "preact"; // Per HTMLAttributes
|
|
1465
1476
|
import { forwardRef } from "preact/compat"; // Per inoltrare i ref
|
|
1466
1477
|
|
|
1467
|
-
export interface LocalizedLinkProps
|
|
1468
|
-
extends JSX.HTMLAttributes<HTMLAnchorElement> {
|
|
1478
|
+
export interface LocalizedLinkProps extends JSX.HTMLAttributes<HTMLAnchorElement> {
|
|
1469
1479
|
href: string;
|
|
1470
1480
|
replace?: boolean; // Opzionale: per sostituire lo stato della cronologia
|
|
1471
1481
|
}
|
|
@@ -72,16 +72,25 @@ Installa i pacchetti necessari usando npm:
|
|
|
72
72
|
```bash packageManager="npm"
|
|
73
73
|
npm install intlayer react-intlayer
|
|
74
74
|
npm install vite-intlayer --save-dev
|
|
75
|
+
npx intlayer init
|
|
75
76
|
```
|
|
76
77
|
|
|
77
78
|
```bash packageManager="pnpm"
|
|
78
79
|
pnpm add intlayer react-intlayer
|
|
79
80
|
pnpm add vite-intlayer --save-dev
|
|
81
|
+
pnpm intlayer init
|
|
80
82
|
```
|
|
81
83
|
|
|
82
84
|
```bash packageManager="yarn"
|
|
83
85
|
yarn add intlayer react-intlayer
|
|
84
86
|
yarn add vite-intlayer --save-dev
|
|
87
|
+
yarn intlayer init
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
```bash packageManager="bun"
|
|
91
|
+
bun add intlayer react-intlayer
|
|
92
|
+
bun add vite-intlayer --dev
|
|
93
|
+
bunx intlayer init
|
|
85
94
|
```
|
|
86
95
|
|
|
87
96
|
- **intlayer**
|
|
@@ -49,16 +49,25 @@ Installa i pacchetti necessari usando npm:
|
|
|
49
49
|
```bash packageManager="npm"
|
|
50
50
|
npm install intlayer solid-intlayer
|
|
51
51
|
npm install vite-intlayer --save-dev
|
|
52
|
+
npx intlayer init
|
|
52
53
|
```
|
|
53
54
|
|
|
54
55
|
```bash packageManager="pnpm"
|
|
55
56
|
pnpm add intlayer solid-intlayer
|
|
56
57
|
pnpm add vite-intlayer --save-dev
|
|
58
|
+
pnpm intlayer init
|
|
57
59
|
```
|
|
58
60
|
|
|
59
61
|
```bash packageManager="yarn"
|
|
60
62
|
yarn add intlayer solid-intlayer
|
|
61
63
|
yarn add vite-intlayer --save-dev
|
|
64
|
+
yarn intlayer init
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
```bash packageManager="bun"
|
|
68
|
+
bun add intlayer solid-intlayer
|
|
69
|
+
bun add vite-intlayer --dev
|
|
70
|
+
bunx intlayer init
|
|
62
71
|
```
|
|
63
72
|
|
|
64
73
|
- **intlayer**
|
|
@@ -62,21 +62,25 @@ Installa i pacchetti necessari usando npm:
|
|
|
62
62
|
```bash packageManager="npm"
|
|
63
63
|
npm install intlayer svelte-intlayer
|
|
64
64
|
npm install vite-intlayer --save-dev
|
|
65
|
+
npx intlayer init
|
|
65
66
|
```
|
|
66
67
|
|
|
67
68
|
```bash packageManager="pnpm"
|
|
68
69
|
pnpm add intlayer svelte-intlayer
|
|
69
70
|
pnpm add vite-intlayer --save-dev
|
|
71
|
+
pnpm intlayer init
|
|
70
72
|
```
|
|
71
73
|
|
|
72
74
|
```bash packageManager="yarn"
|
|
73
75
|
yarn add intlayer svelte-intlayer
|
|
74
76
|
yarn add vite-intlayer --save-dev
|
|
77
|
+
yarn intlayer init
|
|
75
78
|
```
|
|
76
79
|
|
|
77
80
|
```bash packageManager="bun"
|
|
78
81
|
bun add intlayer svelte-intlayer
|
|
79
82
|
bun add vite-intlayer --save-dev
|
|
83
|
+
bunx intlayer init
|
|
80
84
|
```
|
|
81
85
|
|
|
82
86
|
- **intlayer**
|
|
@@ -302,14 +306,17 @@ Per prima cosa, installa `svelte-spa-router`:
|
|
|
302
306
|
|
|
303
307
|
```bash packageManager="npm"
|
|
304
308
|
npm install svelte-spa-router
|
|
309
|
+
npx intlayer init
|
|
305
310
|
```
|
|
306
311
|
|
|
307
312
|
```bash packageManager="pnpm"
|
|
308
313
|
pnpm add svelte-spa-router
|
|
314
|
+
pnpm intlayer init
|
|
309
315
|
```
|
|
310
316
|
|
|
311
317
|
```bash packageManager="yarn"
|
|
312
318
|
yarn add svelte-spa-router
|
|
319
|
+
yarn intlayer init
|
|
313
320
|
```
|
|
314
321
|
|
|
315
322
|
```bash packageManager="bun"
|