@intlayer/docs 9.5.6 → 9.5.7
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/i18next_vs_intlayer-i18next.md +122 -15
- package/blog/ar/i18next_vs_intlayer.md +130 -16
- package/blog/ar/lingui_vs_intlayer.md +122 -15
- package/blog/ar/next-intl_vs_intlayer-next-intl.md +124 -15
- package/blog/ar/next-intl_vs_intlayer.md +136 -20
- package/blog/ar/vue-i18n_vs_intlayer-vue-i18n.md +119 -17
- package/blog/ar/vue-i18n_vs_intlayer.md +193 -31
- package/blog/ar/vue-i18n_vs_intlayer_benchmark.md +361 -0
- package/blog/de/i18next_vs_intlayer-i18next.md +122 -15
- package/blog/de/i18next_vs_intlayer.md +128 -14
- package/blog/de/lingui_vs_intlayer.md +122 -15
- package/blog/de/next-intl_vs_intlayer-next-intl.md +124 -15
- package/blog/de/next-intl_vs_intlayer.md +125 -15
- package/blog/de/vue-i18n_vs_intlayer-vue-i18n.md +117 -17
- package/blog/de/vue-i18n_vs_intlayer.md +193 -31
- package/blog/en/i18next_vs_intlayer-i18next.md +121 -14
- package/blog/en/i18next_vs_intlayer.md +128 -14
- package/blog/en/lingui_vs_intlayer.md +124 -15
- package/blog/en/next-intl_vs_intlayer-next-intl.md +123 -14
- package/blog/en/next-intl_vs_intlayer.md +125 -13
- package/blog/en/vue-i18n_vs_intlayer-vue-i18n.md +115 -15
- package/blog/en/vue-i18n_vs_intlayer.md +188 -27
- package/blog/en-GB/i18next_vs_intlayer-i18next.md +121 -14
- package/blog/en-GB/i18next_vs_intlayer.md +128 -14
- package/blog/en-GB/lingui_vs_intlayer.md +122 -15
- package/blog/en-GB/next-intl_vs_intlayer-next-intl.md +124 -15
- package/blog/en-GB/next-intl_vs_intlayer.md +125 -15
- package/blog/en-GB/vue-i18n_vs_intlayer-vue-i18n.md +117 -17
- package/blog/en-GB/vue-i18n_vs_intlayer.md +187 -25
- package/blog/en-GB/vue-i18n_vs_intlayer_benchmark.md +116 -0
- package/blog/es/i18next_vs_intlayer-i18next.md +122 -15
- package/blog/es/i18next_vs_intlayer.md +128 -14
- package/blog/es/lingui_vs_intlayer.md +122 -15
- package/blog/es/next-intl_vs_intlayer-next-intl.md +124 -15
- package/blog/es/next-intl_vs_intlayer.md +125 -15
- package/blog/es/vue-i18n_vs_intlayer-vue-i18n.md +117 -17
- package/blog/es/vue-i18n_vs_intlayer.md +193 -31
- package/blog/fr/i18next_vs_intlayer-i18next.md +122 -15
- package/blog/fr/i18next_vs_intlayer.md +128 -14
- package/blog/fr/lingui_vs_intlayer.md +122 -15
- package/blog/fr/next-intl_vs_intlayer-next-intl.md +124 -15
- package/blog/fr/next-intl_vs_intlayer.md +127 -15
- package/blog/fr/vue-i18n_vs_intlayer-vue-i18n.md +118 -17
- package/blog/fr/vue-i18n_vs_intlayer.md +192 -31
- package/blog/fr/vue-i18n_vs_intlayer_benchmark.md +329 -7
- package/blog/hi/i18next_vs_intlayer-i18next.md +122 -15
- package/blog/hi/i18next_vs_intlayer.md +130 -16
- package/blog/hi/lingui_vs_intlayer.md +122 -15
- package/blog/hi/next-intl_vs_intlayer-next-intl.md +124 -15
- package/blog/hi/next-intl_vs_intlayer.md +135 -19
- package/blog/hi/vue-i18n_vs_intlayer-vue-i18n.md +117 -17
- package/blog/hi/vue-i18n_vs_intlayer.md +193 -31
- package/blog/hi/vue-i18n_vs_intlayer_benchmark.md +361 -0
- package/blog/id/i18next_vs_intlayer-i18next.md +122 -15
- package/blog/id/i18next_vs_intlayer.md +128 -14
- package/blog/id/lingui_vs_intlayer.md +122 -15
- package/blog/id/next-intl_vs_intlayer-next-intl.md +124 -15
- package/blog/id/next-intl_vs_intlayer.md +135 -19
- package/blog/id/vue-i18n_vs_intlayer-vue-i18n.md +354 -2
- package/blog/id/vue-i18n_vs_intlayer.md +188 -26
- package/blog/id/vue-i18n_vs_intlayer_benchmark.md +327 -7
- package/blog/it/i18next_vs_intlayer-i18next.md +122 -15
- package/blog/it/i18next_vs_intlayer.md +128 -14
- package/blog/it/lingui_vs_intlayer.md +122 -15
- package/blog/it/next-intl_vs_intlayer-next-intl.md +124 -15
- package/blog/it/next-intl_vs_intlayer.md +125 -15
- package/blog/it/vue-i18n_vs_intlayer-vue-i18n.md +117 -17
- package/blog/it/vue-i18n_vs_intlayer.md +191 -31
- package/blog/it/vue-i18n_vs_intlayer_benchmark.md +332 -5
- package/blog/ja/i18next_vs_intlayer-i18next.md +122 -15
- package/blog/ja/i18next_vs_intlayer.md +129 -17
- package/blog/ja/lingui_vs_intlayer.md +122 -15
- package/blog/ja/next-intl_vs_intlayer-next-intl.md +124 -15
- package/blog/ja/next-intl_vs_intlayer.md +124 -14
- package/blog/ja/vue-i18n_vs_intlayer-vue-i18n.md +117 -17
- package/blog/ja/vue-i18n_vs_intlayer.md +193 -31
- package/blog/ja/vue-i18n_vs_intlayer_benchmark.md +361 -0
- package/blog/ko/i18next_vs_intlayer-i18next.md +122 -15
- package/blog/ko/i18next_vs_intlayer.md +129 -17
- package/blog/ko/lingui_vs_intlayer.md +122 -15
- package/blog/ko/next-intl_vs_intlayer-next-intl.md +124 -15
- package/blog/ko/next-intl_vs_intlayer.md +134 -18
- package/blog/ko/vue-i18n_vs_intlayer-vue-i18n.md +117 -17
- package/blog/ko/vue-i18n_vs_intlayer.md +193 -31
- package/blog/pl/i18next_vs_intlayer-i18next.md +122 -15
- package/blog/pl/i18next_vs_intlayer.md +128 -14
- package/blog/pl/lingui_vs_intlayer.md +122 -15
- package/blog/pl/next-intl_vs_intlayer-next-intl.md +124 -15
- package/blog/pl/next-intl_vs_intlayer.md +134 -18
- package/blog/pl/vue-i18n_vs_intlayer-vue-i18n.md +117 -17
- package/blog/pl/vue-i18n_vs_intlayer.md +188 -26
- package/blog/pl/vue-i18n_vs_intlayer_benchmark.md +361 -0
- package/blog/pt/i18next_vs_intlayer-i18next.md +122 -15
- package/blog/pt/i18next_vs_intlayer.md +128 -14
- package/blog/pt/lingui_vs_intlayer.md +122 -15
- package/blog/pt/next-intl_vs_intlayer-next-intl.md +124 -15
- package/blog/pt/next-intl_vs_intlayer.md +131 -15
- package/blog/pt/vue-i18n_vs_intlayer-vue-i18n.md +117 -17
- package/blog/pt/vue-i18n_vs_intlayer.md +193 -31
- package/blog/pt/vue-i18n_vs_intlayer_benchmark.md +361 -0
- package/blog/ru/i18next_vs_intlayer-i18next.md +122 -15
- package/blog/ru/i18next_vs_intlayer.md +130 -16
- package/blog/ru/lingui_vs_intlayer.md +122 -15
- package/blog/ru/next-intl_vs_intlayer-next-intl.md +125 -16
- package/blog/ru/next-intl_vs_intlayer.md +123 -13
- package/blog/ru/vue-i18n_vs_intlayer-vue-i18n.md +127 -27
- package/blog/ru/vue-i18n_vs_intlayer.md +193 -31
- package/blog/ru/vue-i18n_vs_intlayer_benchmark.md +326 -19
- package/blog/tr/i18next_vs_intlayer-i18next.md +122 -15
- package/blog/tr/i18next_vs_intlayer.md +128 -14
- package/blog/tr/lingui_vs_intlayer.md +122 -15
- package/blog/tr/next-intl_vs_intlayer-next-intl.md +124 -15
- package/blog/tr/next-intl_vs_intlayer.md +136 -20
- package/blog/tr/vue-i18n_vs_intlayer-vue-i18n.md +117 -17
- package/blog/tr/vue-i18n_vs_intlayer.md +188 -26
- package/blog/tr/vue-i18n_vs_intlayer_benchmark.md +361 -0
- package/blog/uk/i18next_vs_intlayer-i18next.md +122 -15
- package/blog/uk/i18next_vs_intlayer.md +130 -16
- package/blog/uk/lingui_vs_intlayer.md +122 -15
- package/blog/uk/next-intl_vs_intlayer-next-intl.md +124 -15
- package/blog/uk/next-intl_vs_intlayer.md +135 -19
- package/blog/uk/vue-i18n_vs_intlayer-vue-i18n.md +135 -17
- package/blog/uk/vue-i18n_vs_intlayer.md +188 -27
- package/blog/uk/vue-i18n_vs_intlayer_benchmark.md +361 -0
- package/blog/vi/i18next_vs_intlayer-i18next.md +122 -15
- package/blog/vi/i18next_vs_intlayer.md +128 -14
- package/blog/vi/lingui_vs_intlayer.md +122 -15
- package/blog/vi/next-intl_vs_intlayer-next-intl.md +124 -15
- package/blog/vi/next-intl_vs_intlayer.md +135 -19
- package/blog/vi/vue-i18n_vs_intlayer-vue-i18n.md +117 -17
- package/blog/vi/vue-i18n_vs_intlayer.md +188 -26
- package/blog/vi/vue-i18n_vs_intlayer_benchmark.md +361 -0
- package/blog/zh/i18next_vs_intlayer-i18next.md +122 -15
- package/blog/zh/i18next_vs_intlayer.md +128 -14
- package/blog/zh/lingui_vs_intlayer.md +122 -15
- package/blog/zh/next-intl_vs_intlayer-next-intl.md +124 -15
- package/blog/zh/next-intl_vs_intlayer.md +125 -15
- package/blog/zh/vue-i18n_vs_intlayer-vue-i18n.md +117 -17
- package/blog/zh/vue-i18n_vs_intlayer.md +192 -31
- package/blog/zh/vue-i18n_vs_intlayer_benchmark.md +340 -9
- package/dist/cjs/generated/docs.entry.cjs +40 -40
- package/dist/cjs/generated/docs.entry.cjs.map +1 -1
- package/dist/cjs/index.cjs +2 -2
- package/dist/esm/generated/docs.entry.mjs +40 -40
- package/dist/esm/generated/docs.entry.mjs.map +1 -1
- package/dist/esm/index.mjs +2 -2
- package/dist/types/generated/docs.entry.d.ts +2 -2
- package/dist/types/generated/docs.entry.d.ts.map +1 -1
- package/docs/ar/benchmark/nextjs.md +13 -13
- package/docs/ar/benchmark/solid.md +5 -5
- package/docs/ar/benchmark/svelte.md +4 -4
- package/docs/ar/benchmark/tanstack.md +14 -13
- package/docs/ar/benchmark/vue.md +5 -5
- package/docs/ar/chrome_extension.md +130 -0
- package/docs/ar/cli/index.md +6 -1
- package/docs/ar/cli/infra.md +162 -0
- package/docs/ar/cli/init.md +24 -1
- package/docs/ar/dictionary/html.md +173 -5
- package/docs/ar/dictionary/markdown.md +263 -1
- package/docs/ar/intlayer_with_analog.md +23 -1
- package/docs/ar/intlayer_with_angular_19.md +24 -1
- package/docs/ar/intlayer_with_angular_21.md +24 -1
- package/docs/ar/intlayer_with_astro.md +24 -1
- package/docs/ar/intlayer_with_astro_lit.md +25 -1
- package/docs/ar/intlayer_with_astro_preact.md +26 -1
- package/docs/ar/intlayer_with_astro_react.md +26 -1
- package/docs/ar/intlayer_with_astro_solid.md +26 -1
- package/docs/ar/intlayer_with_astro_svelte.md +25 -1
- package/docs/ar/intlayer_with_astro_vue.md +25 -1
- package/docs/ar/intlayer_with_remix_3.md +22 -1
- package/docs/ar/self_hosting.md +406 -231
- package/docs/de/benchmark/nextjs.md +13 -13
- package/docs/de/benchmark/solid.md +5 -5
- package/docs/de/benchmark/svelte.md +4 -4
- package/docs/de/benchmark/tanstack.md +14 -13
- package/docs/de/benchmark/vue.md +5 -5
- package/docs/de/chrome_extension.md +130 -0
- package/docs/de/cli/index.md +6 -1
- package/docs/de/cli/infra.md +162 -0
- package/docs/de/cli/init.md +24 -1
- package/docs/de/dictionary/html.md +173 -5
- package/docs/de/dictionary/markdown.md +263 -1
- package/docs/de/intlayer_with_analog.md +23 -1
- package/docs/de/intlayer_with_angular_19.md +24 -1
- package/docs/de/intlayer_with_angular_21.md +24 -1
- package/docs/de/intlayer_with_astro.md +24 -1
- package/docs/de/intlayer_with_astro_lit.md +25 -1
- package/docs/de/intlayer_with_astro_preact.md +26 -1
- package/docs/de/intlayer_with_astro_react.md +26 -1
- package/docs/de/intlayer_with_astro_solid.md +26 -1
- package/docs/de/intlayer_with_astro_svelte.md +25 -1
- package/docs/de/intlayer_with_astro_vue.md +25 -1
- package/docs/de/intlayer_with_remix_3.md +22 -1
- package/docs/de/self_hosting.md +404 -227
- package/docs/en/benchmark/nextjs.md +13 -13
- package/docs/en/benchmark/solid.md +5 -5
- package/docs/en/benchmark/svelte.md +4 -4
- package/docs/en/benchmark/tanstack.md +14 -13
- package/docs/en/benchmark/vue.md +5 -5
- package/docs/en/chrome_extension.md +130 -0
- package/docs/en/cli/index.md +6 -1
- package/docs/en/cli/infra.md +175 -0
- package/docs/en/cli/init.md +25 -1
- package/docs/en/dictionary/html.md +173 -5
- package/docs/en/dictionary/markdown.md +263 -1
- package/docs/en/intlayer_with_analog.md +23 -1
- package/docs/en/intlayer_with_angular_19.md +24 -1
- package/docs/en/intlayer_with_angular_21.md +24 -1
- package/docs/en/intlayer_with_astro.md +24 -1
- package/docs/en/intlayer_with_astro_lit.md +25 -1
- package/docs/en/intlayer_with_astro_preact.md +26 -1
- package/docs/en/intlayer_with_astro_react.md +26 -1
- package/docs/en/intlayer_with_astro_solid.md +26 -1
- package/docs/en/intlayer_with_astro_svelte.md +25 -1
- package/docs/en/intlayer_with_astro_vue.md +25 -1
- package/docs/en/intlayer_with_remix_3.md +22 -1
- package/docs/en/self_hosting.md +418 -176
- package/docs/en-GB/benchmark/nextjs.md +13 -13
- package/docs/en-GB/benchmark/solid.md +5 -5
- package/docs/en-GB/benchmark/svelte.md +4 -4
- package/docs/en-GB/benchmark/tanstack.md +14 -13
- package/docs/en-GB/benchmark/vue.md +5 -5
- package/docs/en-GB/chrome_extension.md +130 -0
- package/docs/en-GB/cli/index.md +6 -1
- package/docs/en-GB/cli/infra.md +162 -0
- package/docs/en-GB/cli/init.md +24 -1
- package/docs/en-GB/dictionary/html.md +173 -5
- package/docs/en-GB/dictionary/markdown.md +263 -1
- package/docs/en-GB/intlayer_with_analog.md +23 -1
- package/docs/en-GB/intlayer_with_angular_19.md +24 -1
- package/docs/en-GB/intlayer_with_angular_21.md +24 -1
- package/docs/en-GB/intlayer_with_astro.md +24 -1
- package/docs/en-GB/intlayer_with_astro_lit.md +25 -1
- package/docs/en-GB/intlayer_with_astro_preact.md +26 -1
- package/docs/en-GB/intlayer_with_astro_react.md +26 -1
- package/docs/en-GB/intlayer_with_astro_solid.md +26 -1
- package/docs/en-GB/intlayer_with_astro_svelte.md +25 -1
- package/docs/en-GB/intlayer_with_astro_vue.md +25 -1
- package/docs/en-GB/intlayer_with_remix_3.md +22 -1
- package/docs/en-GB/self_hosting.md +381 -206
- package/docs/es/benchmark/nextjs.md +13 -13
- package/docs/es/benchmark/solid.md +5 -5
- package/docs/es/benchmark/svelte.md +4 -4
- package/docs/es/benchmark/tanstack.md +14 -13
- package/docs/es/benchmark/vue.md +5 -5
- package/docs/es/chrome_extension.md +130 -0
- package/docs/es/cli/index.md +6 -1
- package/docs/es/cli/infra.md +162 -0
- package/docs/es/cli/init.md +24 -1
- package/docs/es/dictionary/html.md +173 -5
- package/docs/es/dictionary/markdown.md +263 -1
- package/docs/es/intlayer_with_analog.md +23 -1
- package/docs/es/intlayer_with_angular_19.md +24 -1
- package/docs/es/intlayer_with_angular_21.md +24 -1
- package/docs/es/intlayer_with_astro.md +24 -1
- package/docs/es/intlayer_with_astro_lit.md +25 -1
- package/docs/es/intlayer_with_astro_preact.md +26 -1
- package/docs/es/intlayer_with_astro_react.md +26 -1
- package/docs/es/intlayer_with_astro_solid.md +26 -1
- package/docs/es/intlayer_with_astro_svelte.md +25 -1
- package/docs/es/intlayer_with_astro_vue.md +25 -1
- package/docs/es/intlayer_with_remix_3.md +22 -1
- package/docs/es/self_hosting.md +400 -223
- package/docs/fr/benchmark/nextjs.md +13 -13
- package/docs/fr/benchmark/solid.md +5 -5
- package/docs/fr/benchmark/svelte.md +4 -4
- package/docs/fr/benchmark/tanstack.md +14 -13
- package/docs/fr/benchmark/vue.md +5 -5
- package/docs/fr/chrome_extension.md +130 -0
- package/docs/fr/cli/index.md +6 -1
- package/docs/fr/cli/infra.md +162 -0
- package/docs/fr/cli/init.md +24 -1
- package/docs/fr/dictionary/html.md +173 -5
- package/docs/fr/dictionary/markdown.md +265 -4
- package/docs/fr/intlayer_with_analog.md +23 -1
- package/docs/fr/intlayer_with_angular_19.md +24 -1
- package/docs/fr/intlayer_with_angular_21.md +24 -1
- package/docs/fr/intlayer_with_astro.md +24 -1
- package/docs/fr/intlayer_with_astro_lit.md +25 -1
- package/docs/fr/intlayer_with_astro_preact.md +26 -1
- package/docs/fr/intlayer_with_astro_react.md +26 -1
- package/docs/fr/intlayer_with_astro_solid.md +26 -1
- package/docs/fr/intlayer_with_astro_svelte.md +25 -1
- package/docs/fr/intlayer_with_astro_vue.md +25 -1
- package/docs/fr/intlayer_with_remix_3.md +22 -1
- package/docs/fr/self_hosting.md +401 -224
- package/docs/hi/benchmark/nextjs.md +13 -13
- package/docs/hi/benchmark/solid.md +5 -5
- package/docs/hi/benchmark/svelte.md +4 -4
- package/docs/hi/benchmark/tanstack.md +14 -13
- package/docs/hi/benchmark/vue.md +5 -5
- package/docs/hi/chrome_extension.md +130 -0
- package/docs/hi/cli/index.md +6 -1
- package/docs/hi/cli/infra.md +162 -0
- package/docs/hi/cli/init.md +24 -1
- package/docs/hi/dictionary/html.md +173 -5
- package/docs/hi/dictionary/markdown.md +263 -1
- package/docs/hi/intlayer_with_analog.md +23 -1
- package/docs/hi/intlayer_with_angular_19.md +24 -1
- package/docs/hi/intlayer_with_angular_21.md +24 -1
- package/docs/hi/intlayer_with_astro.md +24 -1
- package/docs/hi/intlayer_with_astro_lit.md +25 -1
- package/docs/hi/intlayer_with_astro_preact.md +26 -1
- package/docs/hi/intlayer_with_astro_react.md +26 -1
- package/docs/hi/intlayer_with_astro_solid.md +26 -1
- package/docs/hi/intlayer_with_astro_svelte.md +25 -1
- package/docs/hi/intlayer_with_astro_vue.md +25 -1
- package/docs/hi/intlayer_with_remix_3.md +22 -1
- package/docs/hi/self_hosting.md +409 -235
- package/docs/id/benchmark/nextjs.md +13 -13
- package/docs/id/benchmark/solid.md +5 -5
- package/docs/id/benchmark/svelte.md +4 -4
- package/docs/id/benchmark/tanstack.md +14 -13
- package/docs/id/benchmark/vue.md +5 -5
- package/docs/id/chrome_extension.md +130 -0
- package/docs/id/cli/index.md +6 -1
- package/docs/id/cli/infra.md +162 -0
- package/docs/id/cli/init.md +24 -1
- package/docs/id/dictionary/html.md +173 -5
- package/docs/id/dictionary/markdown.md +263 -1
- package/docs/id/intlayer_with_analog.md +23 -1
- package/docs/id/intlayer_with_angular_19.md +24 -1
- package/docs/id/intlayer_with_angular_21.md +24 -1
- package/docs/id/intlayer_with_astro.md +24 -1
- package/docs/id/intlayer_with_astro_lit.md +25 -1
- package/docs/id/intlayer_with_astro_preact.md +26 -1
- package/docs/id/intlayer_with_astro_react.md +26 -1
- package/docs/id/intlayer_with_astro_solid.md +26 -1
- package/docs/id/intlayer_with_astro_svelte.md +25 -1
- package/docs/id/intlayer_with_astro_vue.md +25 -1
- package/docs/id/intlayer_with_remix_3.md +22 -1
- package/docs/id/self_hosting.md +416 -243
- package/docs/it/benchmark/nextjs.md +13 -13
- package/docs/it/benchmark/solid.md +5 -5
- package/docs/it/benchmark/svelte.md +4 -4
- package/docs/it/benchmark/tanstack.md +14 -13
- package/docs/it/benchmark/vue.md +5 -5
- package/docs/it/chrome_extension.md +130 -0
- package/docs/it/cli/index.md +6 -1
- package/docs/it/cli/infra.md +162 -0
- package/docs/it/cli/init.md +24 -1
- package/docs/it/dictionary/html.md +173 -5
- package/docs/it/dictionary/markdown.md +263 -1
- package/docs/it/intlayer_with_analog.md +23 -1
- package/docs/it/intlayer_with_angular_19.md +24 -1
- package/docs/it/intlayer_with_angular_21.md +24 -1
- package/docs/it/intlayer_with_astro.md +24 -1
- package/docs/it/intlayer_with_astro_lit.md +25 -1
- package/docs/it/intlayer_with_astro_preact.md +26 -1
- package/docs/it/intlayer_with_astro_react.md +26 -1
- package/docs/it/intlayer_with_astro_solid.md +26 -1
- package/docs/it/intlayer_with_astro_svelte.md +25 -1
- package/docs/it/intlayer_with_astro_vue.md +25 -1
- package/docs/it/intlayer_with_remix_3.md +22 -1
- package/docs/it/self_hosting.md +412 -237
- package/docs/ja/benchmark/nextjs.md +13 -13
- package/docs/ja/benchmark/solid.md +5 -5
- package/docs/ja/benchmark/svelte.md +4 -4
- package/docs/ja/benchmark/tanstack.md +13 -12
- package/docs/ja/benchmark/vue.md +5 -5
- package/docs/ja/chrome_extension.md +130 -0
- package/docs/ja/cli/index.md +6 -1
- package/docs/ja/cli/infra.md +162 -0
- package/docs/ja/cli/init.md +24 -1
- package/docs/ja/dictionary/html.md +173 -5
- package/docs/ja/dictionary/markdown.md +263 -1
- package/docs/ja/intlayer_with_analog.md +23 -1
- package/docs/ja/intlayer_with_angular_19.md +24 -1
- package/docs/ja/intlayer_with_angular_21.md +24 -1
- package/docs/ja/intlayer_with_astro.md +24 -1
- package/docs/ja/intlayer_with_astro_lit.md +25 -1
- package/docs/ja/intlayer_with_astro_preact.md +26 -1
- package/docs/ja/intlayer_with_astro_react.md +26 -1
- package/docs/ja/intlayer_with_astro_solid.md +26 -1
- package/docs/ja/intlayer_with_astro_svelte.md +25 -1
- package/docs/ja/intlayer_with_astro_vue.md +25 -1
- package/docs/ja/intlayer_with_remix_3.md +22 -1
- package/docs/ja/self_hosting.md +398 -223
- package/docs/ko/benchmark/nextjs.md +13 -13
- package/docs/ko/benchmark/solid.md +5 -5
- package/docs/ko/benchmark/svelte.md +4 -4
- package/docs/ko/benchmark/tanstack.md +14 -13
- package/docs/ko/benchmark/vue.md +5 -5
- package/docs/ko/chrome_extension.md +130 -0
- package/docs/ko/cli/index.md +6 -1
- package/docs/ko/cli/infra.md +162 -0
- package/docs/ko/cli/init.md +24 -1
- package/docs/ko/dictionary/html.md +173 -5
- package/docs/ko/dictionary/markdown.md +263 -1
- package/docs/ko/intlayer_with_analog.md +23 -1
- package/docs/ko/intlayer_with_angular_19.md +24 -1
- package/docs/ko/intlayer_with_angular_21.md +24 -1
- package/docs/ko/intlayer_with_astro.md +24 -1
- package/docs/ko/intlayer_with_astro_lit.md +25 -1
- package/docs/ko/intlayer_with_astro_preact.md +26 -1
- package/docs/ko/intlayer_with_astro_react.md +26 -1
- package/docs/ko/intlayer_with_astro_solid.md +26 -1
- package/docs/ko/intlayer_with_astro_svelte.md +25 -1
- package/docs/ko/intlayer_with_astro_vue.md +25 -1
- package/docs/ko/intlayer_with_remix_3.md +22 -1
- package/docs/ko/self_hosting.md +411 -238
- package/docs/pl/benchmark/nextjs.md +13 -13
- package/docs/pl/benchmark/solid.md +5 -5
- package/docs/pl/benchmark/svelte.md +4 -4
- package/docs/pl/benchmark/tanstack.md +14 -13
- package/docs/pl/benchmark/vue.md +5 -5
- package/docs/pl/chrome_extension.md +130 -0
- package/docs/pl/cli/index.md +6 -1
- package/docs/pl/cli/infra.md +162 -0
- package/docs/pl/cli/init.md +24 -1
- package/docs/pl/dictionary/html.md +173 -5
- package/docs/pl/dictionary/markdown.md +263 -1
- package/docs/pl/intlayer_with_analog.md +23 -1
- package/docs/pl/intlayer_with_angular_19.md +24 -1
- package/docs/pl/intlayer_with_angular_21.md +24 -1
- package/docs/pl/intlayer_with_astro.md +24 -1
- package/docs/pl/intlayer_with_astro_lit.md +25 -1
- package/docs/pl/intlayer_with_astro_preact.md +26 -1
- package/docs/pl/intlayer_with_astro_react.md +26 -1
- package/docs/pl/intlayer_with_astro_solid.md +26 -1
- package/docs/pl/intlayer_with_astro_svelte.md +25 -1
- package/docs/pl/intlayer_with_astro_vue.md +25 -1
- package/docs/pl/intlayer_with_remix_3.md +22 -1
- package/docs/pl/self_hosting.md +408 -233
- package/docs/pt/benchmark/nextjs.md +13 -13
- package/docs/pt/benchmark/solid.md +5 -5
- package/docs/pt/benchmark/svelte.md +4 -4
- package/docs/pt/benchmark/tanstack.md +14 -13
- package/docs/pt/benchmark/vue.md +5 -5
- package/docs/pt/chrome_extension.md +130 -0
- package/docs/pt/cli/index.md +6 -1
- package/docs/pt/cli/infra.md +162 -0
- package/docs/pt/cli/init.md +24 -1
- package/docs/pt/dictionary/html.md +173 -5
- package/docs/pt/dictionary/markdown.md +263 -1
- package/docs/pt/intlayer_with_analog.md +23 -1
- package/docs/pt/intlayer_with_angular_19.md +24 -1
- package/docs/pt/intlayer_with_angular_21.md +24 -1
- package/docs/pt/intlayer_with_astro.md +24 -1
- package/docs/pt/intlayer_with_astro_lit.md +25 -1
- package/docs/pt/intlayer_with_astro_preact.md +26 -1
- package/docs/pt/intlayer_with_astro_react.md +26 -1
- package/docs/pt/intlayer_with_astro_solid.md +26 -1
- package/docs/pt/intlayer_with_astro_svelte.md +25 -1
- package/docs/pt/intlayer_with_astro_vue.md +25 -1
- package/docs/pt/intlayer_with_remix_3.md +22 -1
- package/docs/pt/self_hosting.md +399 -224
- package/docs/ru/benchmark/nextjs.md +13 -13
- package/docs/ru/benchmark/solid.md +5 -5
- package/docs/ru/benchmark/svelte.md +4 -4
- package/docs/ru/benchmark/tanstack.md +14 -13
- package/docs/ru/benchmark/vue.md +5 -5
- package/docs/ru/chrome_extension.md +130 -0
- package/docs/ru/cli/index.md +6 -1
- package/docs/ru/cli/infra.md +162 -0
- package/docs/ru/cli/init.md +24 -1
- package/docs/ru/dictionary/html.md +173 -5
- package/docs/ru/dictionary/markdown.md +263 -1
- package/docs/ru/intlayer_with_analog.md +23 -1
- package/docs/ru/intlayer_with_angular_19.md +24 -1
- package/docs/ru/intlayer_with_angular_21.md +24 -1
- package/docs/ru/intlayer_with_astro.md +24 -1
- package/docs/ru/intlayer_with_astro_lit.md +25 -1
- package/docs/ru/intlayer_with_astro_preact.md +26 -1
- package/docs/ru/intlayer_with_astro_react.md +26 -1
- package/docs/ru/intlayer_with_astro_solid.md +26 -1
- package/docs/ru/intlayer_with_astro_svelte.md +25 -1
- package/docs/ru/intlayer_with_astro_vue.md +25 -1
- package/docs/ru/intlayer_with_remix_3.md +22 -1
- package/docs/ru/self_hosting.md +403 -228
- package/docs/tr/benchmark/nextjs.md +13 -13
- package/docs/tr/benchmark/solid.md +5 -5
- package/docs/tr/benchmark/svelte.md +4 -4
- package/docs/tr/benchmark/tanstack.md +14 -13
- package/docs/tr/benchmark/vue.md +5 -5
- package/docs/tr/chrome_extension.md +130 -0
- package/docs/tr/cli/index.md +6 -1
- package/docs/tr/cli/infra.md +162 -0
- package/docs/tr/cli/init.md +24 -1
- package/docs/tr/dictionary/html.md +173 -5
- package/docs/tr/dictionary/markdown.md +263 -1
- package/docs/tr/intlayer_with_analog.md +23 -1
- package/docs/tr/intlayer_with_angular_19.md +24 -1
- package/docs/tr/intlayer_with_angular_21.md +24 -1
- package/docs/tr/intlayer_with_astro.md +24 -1
- package/docs/tr/intlayer_with_astro_lit.md +25 -1
- package/docs/tr/intlayer_with_astro_preact.md +26 -1
- package/docs/tr/intlayer_with_astro_react.md +26 -1
- package/docs/tr/intlayer_with_astro_solid.md +26 -1
- package/docs/tr/intlayer_with_astro_svelte.md +25 -1
- package/docs/tr/intlayer_with_astro_vue.md +25 -1
- package/docs/tr/intlayer_with_remix_3.md +22 -1
- package/docs/tr/self_hosting.md +410 -234
- package/docs/uk/benchmark/nextjs.md +13 -13
- package/docs/uk/benchmark/solid.md +5 -5
- package/docs/uk/benchmark/svelte.md +4 -4
- package/docs/uk/benchmark/tanstack.md +14 -13
- package/docs/uk/benchmark/vue.md +5 -5
- package/docs/uk/chrome_extension.md +130 -0
- package/docs/uk/cli/index.md +6 -1
- package/docs/uk/cli/infra.md +162 -0
- package/docs/uk/cli/init.md +24 -1
- package/docs/uk/dictionary/html.md +173 -5
- package/docs/uk/dictionary/markdown.md +263 -1
- package/docs/uk/intlayer_with_analog.md +23 -1
- package/docs/uk/intlayer_with_angular_19.md +24 -1
- package/docs/uk/intlayer_with_angular_21.md +24 -1
- package/docs/uk/intlayer_with_astro.md +24 -1
- package/docs/uk/intlayer_with_astro_lit.md +25 -1
- package/docs/uk/intlayer_with_astro_preact.md +26 -1
- package/docs/uk/intlayer_with_astro_react.md +26 -1
- package/docs/uk/intlayer_with_astro_solid.md +26 -1
- package/docs/uk/intlayer_with_astro_svelte.md +25 -1
- package/docs/uk/intlayer_with_astro_vue.md +25 -1
- package/docs/uk/intlayer_with_remix_3.md +22 -1
- package/docs/uk/self_hosting.md +413 -238
- package/docs/vi/benchmark/nextjs.md +13 -13
- package/docs/vi/benchmark/solid.md +5 -5
- package/docs/vi/benchmark/svelte.md +4 -4
- package/docs/vi/benchmark/tanstack.md +14 -13
- package/docs/vi/benchmark/vue.md +5 -5
- package/docs/vi/chrome_extension.md +130 -0
- package/docs/vi/cli/index.md +6 -1
- package/docs/vi/cli/infra.md +162 -0
- package/docs/vi/cli/init.md +24 -1
- package/docs/vi/dictionary/html.md +173 -5
- package/docs/vi/dictionary/markdown.md +263 -1
- package/docs/vi/intlayer_with_analog.md +23 -1
- package/docs/vi/intlayer_with_angular_19.md +24 -1
- package/docs/vi/intlayer_with_angular_21.md +24 -1
- package/docs/vi/intlayer_with_astro.md +24 -1
- package/docs/vi/intlayer_with_astro_lit.md +25 -1
- package/docs/vi/intlayer_with_astro_preact.md +26 -1
- package/docs/vi/intlayer_with_astro_react.md +26 -1
- package/docs/vi/intlayer_with_astro_solid.md +26 -1
- package/docs/vi/intlayer_with_astro_svelte.md +25 -1
- package/docs/vi/intlayer_with_astro_vue.md +25 -1
- package/docs/vi/intlayer_with_remix_3.md +22 -1
- package/docs/vi/self_hosting.md +408 -234
- package/docs/zh/benchmark/nextjs.md +13 -13
- package/docs/zh/benchmark/solid.md +5 -5
- package/docs/zh/benchmark/svelte.md +4 -4
- package/docs/zh/benchmark/tanstack.md +14 -13
- package/docs/zh/benchmark/vue.md +5 -5
- package/docs/zh/chrome_extension.md +130 -0
- package/docs/zh/cli/index.md +6 -1
- package/docs/zh/cli/infra.md +162 -0
- package/docs/zh/cli/init.md +24 -1
- package/docs/zh/dictionary/html.md +172 -5
- package/docs/zh/dictionary/markdown.md +262 -1
- package/docs/zh/intlayer_with_analog.md +23 -1
- package/docs/zh/intlayer_with_angular_19.md +24 -1
- package/docs/zh/intlayer_with_angular_21.md +24 -1
- package/docs/zh/intlayer_with_astro.md +24 -1
- package/docs/zh/intlayer_with_astro_lit.md +25 -1
- package/docs/zh/intlayer_with_astro_preact.md +26 -1
- package/docs/zh/intlayer_with_astro_react.md +26 -1
- package/docs/zh/intlayer_with_astro_solid.md +26 -1
- package/docs/zh/intlayer_with_astro_svelte.md +25 -1
- package/docs/zh/intlayer_with_astro_vue.md +25 -1
- package/docs/zh/intlayer_with_remix_3.md +22 -1
- package/docs/zh/self_hosting.md +410 -237
- package/legal/ar/privacy_notice.md +9 -3
- package/legal/de/privacy_notice.md +9 -3
- package/legal/en/privacy_notice.md +10 -3
- package/legal/en-GB/privacy_notice.md +9 -3
- package/legal/es/privacy_notice.md +9 -3
- package/legal/fr/privacy_notice.md +9 -3
- package/legal/hi/privacy_notice.md +9 -3
- package/legal/id/privacy_notice.md +9 -3
- package/legal/it/privacy_notice.md +9 -3
- package/legal/ja/privacy_notice.md +9 -3
- package/legal/ko/privacy_notice.md +9 -3
- package/legal/pl/privacy_notice.md +9 -3
- package/legal/pt/privacy_notice.md +9 -3
- package/legal/ru/privacy_notice.md +9 -3
- package/legal/tr/privacy_notice.md +9 -3
- package/legal/uk/privacy_notice.md +9 -3
- package/legal/vi/privacy_notice.md +9 -3
- package/legal/zh/privacy_notice.md +9 -3
- package/package.json +1 -1
- package/src/generated/docs.entry.ts +40 -40
- package/docs/ar/roadmap.md +0 -321
- package/docs/de/roadmap.md +0 -322
- package/docs/en/intlayer_with_astro_vanilla.md +0 -713
- package/docs/en/roadmap.md +0 -325
- package/docs/en-GB/roadmap.md +0 -322
- package/docs/es/roadmap.md +0 -322
- package/docs/fr/roadmap.md +0 -322
- package/docs/hi/roadmap.md +0 -322
- package/docs/id/roadmap.md +0 -325
- package/docs/it/roadmap.md +0 -322
- package/docs/ja/roadmap.md +0 -322
- package/docs/ko/roadmap.md +0 -322
- package/docs/pl/roadmap.md +0 -325
- package/docs/pt/roadmap.md +0 -322
- package/docs/ru/roadmap.md +0 -322
- package/docs/tr/roadmap.md +0 -325
- package/docs/uk/roadmap.md +0 -325
- package/docs/vi/roadmap.md +0 -325
- package/docs/zh/roadmap.md +0 -322
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
createdAt: 2026-01-20
|
|
3
|
-
updatedAt: 2026-
|
|
3
|
+
updatedAt: 2026-09-21
|
|
4
4
|
title: Contenuto HTML
|
|
5
5
|
description: Scopri come dichiarare e usare contenuti HTML con componenti personalizzati in Intlayer. Segui questa documentazione per incorporare contenuti ricchi in stile HTML con sostituzione dinamica dei componenti nel tuo progetto internazionalizzato.
|
|
6
6
|
keywords:
|
|
@@ -13,6 +13,8 @@ keywords:
|
|
|
13
13
|
- React
|
|
14
14
|
- Vue
|
|
15
15
|
- Svelte
|
|
16
|
+
- Remix
|
|
17
|
+
- Astro
|
|
16
18
|
- Solid
|
|
17
19
|
- Angular
|
|
18
20
|
slugs:
|
|
@@ -238,6 +240,83 @@ Quando accedi al contenuto tramite `useIntlayer`, i nodi HTML sono già pronti p
|
|
|
238
240
|
```
|
|
239
241
|
|
|
240
242
|
</Tab>
|
|
243
|
+
<Tab label="Remix" value="remix">
|
|
244
|
+
In Remix 3, i nodi HTML si risolvono in una stringa HTML. Inseriscila con la prop `innerHTML` di Remix JSX o con `html.raw` in una vista `html-template`.
|
|
245
|
+
|
|
246
|
+
```tsx fileName="src/views/home.tsx"
|
|
247
|
+
import { useIntlayer } from "remix-intlayer";
|
|
248
|
+
|
|
249
|
+
export const HomePage = () => () => {
|
|
250
|
+
const { myHtmlContent } = useIntlayer("app");
|
|
251
|
+
|
|
252
|
+
return <div innerHTML={myHtmlContent.value} />;
|
|
253
|
+
};
|
|
254
|
+
```
|
|
255
|
+
|
|
256
|
+
```ts fileName="src/views/home.ts"
|
|
257
|
+
import { html } from "remix/html-template";
|
|
258
|
+
import { useIntlayer } from "remix-intlayer";
|
|
259
|
+
|
|
260
|
+
export const renderHomePage = () => {
|
|
261
|
+
const { myHtmlContent } = useIntlayer("app");
|
|
262
|
+
|
|
263
|
+
return html.raw`<div>${myHtmlContent.value}</div>`;
|
|
264
|
+
};
|
|
265
|
+
```
|
|
266
|
+
|
|
267
|
+
> Remix esegue l'escape dei valori interpolati per impostazione predefinita. `innerHTML` e `html.raw` sono i due meccanismi di esclusione, che è ciò di cui ha bisogno una stringa HTML.
|
|
268
|
+
|
|
269
|
+
Usa il metodo `.use()` per sovrascrivere i tag o mappare componenti personalizzati. Le sovrascritture sono funzioni che restituiscono una stringa HTML:
|
|
270
|
+
|
|
271
|
+
```tsx
|
|
272
|
+
<div
|
|
273
|
+
innerHTML={myHtmlContent.use({
|
|
274
|
+
p: ({ children }) => `<p class="prose">${children}</p>`,
|
|
275
|
+
CustomLink: ({ children }) => `<a href="/details">${children}</a>`,
|
|
276
|
+
})}
|
|
277
|
+
/>
|
|
278
|
+
```
|
|
279
|
+
|
|
280
|
+
</Tab>
|
|
281
|
+
<Tab label="Astro" value="astro">
|
|
282
|
+
In Astro, i nodi HTML si risolvono in una stringa HTML. Inseriscila con la direttiva `set:html` nel template o con `innerHTML` in uno `<script>` client.
|
|
283
|
+
|
|
284
|
+
```astro fileName="src/pages/index.astro"
|
|
285
|
+
---
|
|
286
|
+
import { useIntlayer } from "astro-intlayer";
|
|
287
|
+
|
|
288
|
+
const { myHtmlContent } = useIntlayer("app");
|
|
289
|
+
---
|
|
290
|
+
|
|
291
|
+
<div set:html={myHtmlContent.value} />
|
|
292
|
+
```
|
|
293
|
+
|
|
294
|
+
```astro fileName="src/components/Content.astro"
|
|
295
|
+
<div id="content"></div>
|
|
296
|
+
|
|
297
|
+
<script>
|
|
298
|
+
import { useIntlayer } from "astro-intlayer";
|
|
299
|
+
|
|
300
|
+
const { myHtmlContent } = useIntlayer("app");
|
|
301
|
+
|
|
302
|
+
document.querySelector("#content")!.innerHTML = myHtmlContent.value;
|
|
303
|
+
</script>
|
|
304
|
+
```
|
|
305
|
+
|
|
306
|
+
> Astro esegue l'escape di `{espressioni}` per impostazione predefinita. `set:html` è il meccanismo di esclusione, che è ciò di cui ha bisogno una stringa HTML.
|
|
307
|
+
|
|
308
|
+
Usa il metodo `.use()` per sovrascrivere i tag o mappare componenti personalizzati. Le sovrascritture sono funzioni che restituiscono una stringa HTML:
|
|
309
|
+
|
|
310
|
+
```astro
|
|
311
|
+
<div
|
|
312
|
+
set:html={myHtmlContent.use({
|
|
313
|
+
p: ({ children }) => `<p class="prose">${children}</p>`,
|
|
314
|
+
CustomLink: ({ children }) => `<a href="/details">${children}</a>`,
|
|
315
|
+
})}
|
|
316
|
+
/>
|
|
317
|
+
```
|
|
318
|
+
|
|
319
|
+
</Tab>
|
|
241
320
|
</Tabs>
|
|
242
321
|
|
|
243
322
|
## Configurazione globale con `HTMLProvider`
|
|
@@ -473,6 +552,41 @@ Puoi configurare il rendering HTML a livello globale per l'intera applicazione.
|
|
|
473
552
|
> Importare dinamicamente il tuo renderer HTML è un ottimo modo per ridurre le dimensioni del bundle della tua applicazione.
|
|
474
553
|
|
|
475
554
|
</Tab>
|
|
555
|
+
<Tab label="Remix" value="remix">
|
|
556
|
+
|
|
557
|
+
Remix non ha un albero dei componenti per contenere un provider, quindi la configurazione viene installata una sola volta, come singleton, all'avvio del server. Configura il renderer restituito da `useHTMLRenderer()`. I nodi `html` restituiti da `useIntlayer` vengono renderizzati così come sono; sovrascrivi i loro tag per nodo con `.use()`.
|
|
558
|
+
|
|
559
|
+
```typescript fileName="src/router.ts"
|
|
560
|
+
import { installIntlayerHTML } from "remix-intlayer/html";
|
|
561
|
+
|
|
562
|
+
installIntlayerHTML({
|
|
563
|
+
renderHTML: (html) => html.replaceAll("<p>", '<p class="prose">'),
|
|
564
|
+
});
|
|
565
|
+
```
|
|
566
|
+
|
|
567
|
+
> Usa `installIntlayerHTMLDynamic(async () => …)` per caricare il renderer in modo lazy; il loader viene eseguito solo alla prima chiamata.
|
|
568
|
+
|
|
569
|
+
</Tab>
|
|
570
|
+
<Tab label="Astro" value="astro">
|
|
571
|
+
|
|
572
|
+
Astro non ha un albero dei componenti per contenere un provider, quindi la configurazione viene installata una sola volta, come singleton, nel middleware (server) e in uno `<script>` client (browser). Configura il renderer restituito da `useHTMLRenderer()`. I nodi `html` restituiti da `useIntlayer` vengono renderizzati così come sono; sovrascrivi i loro tag per nodo con `.use()`.
|
|
573
|
+
|
|
574
|
+
```typescript fileName="src/middleware.ts"
|
|
575
|
+
import { installIntlayerHTML } from "astro-intlayer/html";
|
|
576
|
+
import { defineMiddleware } from "astro:middleware";
|
|
577
|
+
|
|
578
|
+
// Viene eseguito una sola volta all'avvio del server; il middleware Intlayer stesso è
|
|
579
|
+
// registrato dall'integrazione, prima di questo file.
|
|
580
|
+
installIntlayerHTML({
|
|
581
|
+
renderHTML: (html) => html.replaceAll("<p>", '<p class="prose">'),
|
|
582
|
+
});
|
|
583
|
+
|
|
584
|
+
export const onRequest = defineMiddleware((_context, next) => next());
|
|
585
|
+
```
|
|
586
|
+
|
|
587
|
+
> Usa `installIntlayerHTMLDynamic(async () => …)` per caricare il renderer in modo lazy; il loader viene eseguito solo alla prima chiamata.
|
|
588
|
+
|
|
589
|
+
</Tab>
|
|
476
590
|
</Tabs>
|
|
477
591
|
|
|
478
592
|
### Rendering manuale e strumenti avanzati
|
|
@@ -645,15 +759,69 @@ Se hai bisogno di renderizzare stringhe HTML grezze o di avere un controllo magg
|
|
|
645
759
|
```
|
|
646
760
|
|
|
647
761
|
</Tab>
|
|
762
|
+
<Tab label="Remix" value="remix">
|
|
763
|
+
#### Hook `useHTMLRenderer()`
|
|
764
|
+
|
|
765
|
+
Ottieni una funzione di rendering preconfigurata da `installIntlayerHTML()`. Restituisce una stringa HTML.
|
|
766
|
+
|
|
767
|
+
```tsx
|
|
768
|
+
import { useHTMLRenderer } from "remix-intlayer/html";
|
|
769
|
+
|
|
770
|
+
const renderHTML = useHTMLRenderer();
|
|
771
|
+
|
|
772
|
+
return <div innerHTML={renderHTML("<p>Hello <strong>World</strong></p>")} />;
|
|
773
|
+
```
|
|
774
|
+
|
|
775
|
+
#### Utility `renderHTML()`
|
|
776
|
+
|
|
777
|
+
Utility autonoma che ignora la configurazione globale.
|
|
778
|
+
|
|
779
|
+
```tsx
|
|
780
|
+
import { renderHTML } from "remix-intlayer/html";
|
|
781
|
+
|
|
782
|
+
const html = renderHTML("<p>Hello</p>");
|
|
783
|
+
```
|
|
784
|
+
|
|
785
|
+
</Tab>
|
|
786
|
+
<Tab label="Astro" value="astro">
|
|
787
|
+
#### Hook `useHTMLRenderer()`
|
|
788
|
+
|
|
789
|
+
Ottieni una funzione di rendering preconfigurata da `installIntlayerHTML()`. Restituisce una stringa HTML.
|
|
790
|
+
|
|
791
|
+
```astro
|
|
792
|
+
---
|
|
793
|
+
import { useHTMLRenderer } from "astro-intlayer/html";
|
|
794
|
+
|
|
795
|
+
const renderHTML = useHTMLRenderer();
|
|
796
|
+
---
|
|
797
|
+
|
|
798
|
+
<div set:html={renderHTML("<p>Hello <strong>World</strong></p>")} />
|
|
799
|
+
```
|
|
800
|
+
|
|
801
|
+
#### Utility `renderHTML()`
|
|
802
|
+
|
|
803
|
+
Utility autonoma che ignora la configurazione globale.
|
|
804
|
+
|
|
805
|
+
```astro
|
|
806
|
+
---
|
|
807
|
+
import { renderHTML } from "astro-intlayer/html";
|
|
808
|
+
|
|
809
|
+
const html = renderHTML("<p>Hello</p>");
|
|
810
|
+
---
|
|
811
|
+
|
|
812
|
+
<div set:html={html} />
|
|
813
|
+
```
|
|
814
|
+
|
|
815
|
+
</Tab>
|
|
648
816
|
</Tabs>
|
|
649
817
|
|
|
650
818
|
## Riferimento delle opzioni
|
|
651
819
|
|
|
652
820
|
Queste opzioni possono essere passate a `HTMLProvider`, `HTMLRenderer`, `useHTMLRenderer`, e `renderHTML`.
|
|
653
821
|
|
|
654
|
-
| Opzione | Tipo | Predefinito | Descrizione
|
|
655
|
-
| :----------- | :-------------------- | :---------- |
|
|
656
|
-
| `components` | `Record<string, any>` | `{}` | Una mappa che associa tag HTML o nomi di componenti personalizzati ai componenti.
|
|
657
|
-
| `renderHTML` | `Function` | `null` | Una funzione di rendering personalizzata per sostituire completamente il parser HTML predefinito (
|
|
822
|
+
| Opzione | Tipo | Predefinito | Descrizione |
|
|
823
|
+
| :----------- | :-------------------- | :---------- | :-------------------------------------------------------------------------------------------------------------------------------------- |
|
|
824
|
+
| `components` | `Record<string, any>` | `{}` | Una mappa che associa tag HTML o nomi di componenti personalizzati ai componenti. |
|
|
825
|
+
| `renderHTML` | `Function` | `null` | Una funzione di rendering personalizzata per sostituire completamente il parser HTML predefinito (provider Vue, Svelte, Remix e Astro). |
|
|
658
826
|
|
|
659
827
|
> Nota: per React e Preact, i tag HTML standard sono forniti automaticamente. È necessario passare la prop `components` solo se si desidera sovrascriverli o aggiungere componenti personalizzati.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
createdAt: 2025-02-07
|
|
3
|
-
updatedAt: 2026-
|
|
3
|
+
updatedAt: 2026-09-21
|
|
4
4
|
title: Markdown
|
|
5
5
|
description: Scopri come dichiarare e utilizzare i contenuti Markdown nel tuo sito web multilingue con Intlayer. Segui i passaggi in questa documentazione online per integrare perfettamente Markdown nel tuo progetto.
|
|
6
6
|
keywords:
|
|
@@ -11,6 +11,8 @@ keywords:
|
|
|
11
11
|
- Next.js
|
|
12
12
|
- JavaScript
|
|
13
13
|
- React
|
|
14
|
+
- Remix
|
|
15
|
+
- Astro
|
|
14
16
|
slugs:
|
|
15
17
|
- doc
|
|
16
18
|
- concept
|
|
@@ -487,6 +489,111 @@ Il rendering del Markdown supporta **MDX** — usa qualsiasi componente JSX/fram
|
|
|
487
489
|
```
|
|
488
490
|
|
|
489
491
|
</Tab>
|
|
492
|
+
<Tab label="Remix" value="remix">
|
|
493
|
+
In Remix 3, i nodi Markdown vengono renderizzati sul server in una stringa HTML. Inseriscila con la prop `innerHTML` di Remix JSX o con `html.raw` in una vista `html-template`.
|
|
494
|
+
|
|
495
|
+
```tsx fileName="src/views/home.tsx"
|
|
496
|
+
import { useIntlayer } from "remix-intlayer";
|
|
497
|
+
|
|
498
|
+
export const HomePage = () => () => {
|
|
499
|
+
const { myMarkdownContent } = useIntlayer("app");
|
|
500
|
+
|
|
501
|
+
return <div innerHTML={myMarkdownContent.value} />;
|
|
502
|
+
};
|
|
503
|
+
```
|
|
504
|
+
|
|
505
|
+
```ts fileName="src/views/home.ts"
|
|
506
|
+
import { html } from "remix/html-template";
|
|
507
|
+
import { useIntlayer } from "remix-intlayer";
|
|
508
|
+
|
|
509
|
+
export const renderHomePage = () => {
|
|
510
|
+
const { myMarkdownContent } = useIntlayer("app");
|
|
511
|
+
|
|
512
|
+
return html.raw`<div>${myMarkdownContent.value}</div>`;
|
|
513
|
+
};
|
|
514
|
+
```
|
|
515
|
+
|
|
516
|
+
> Remix esegue l'escape dei valori interpolati per impostazione predefinita. `innerHTML` e `html.raw` sono i due meccanismi di esclusione, che è ciò di cui ha bisogno una stringa Markdown renderizzata.
|
|
517
|
+
|
|
518
|
+
Puoi anche fornire override locali per tag specifici utilizzando il metodo `.use()`. Gli override sono funzioni che restituiscono una stringa HTML:
|
|
519
|
+
|
|
520
|
+
```tsx
|
|
521
|
+
<div
|
|
522
|
+
innerHTML={myMarkdownContent.use({
|
|
523
|
+
h1: ({ children }) => `<h1 class="text-3xl font-bold">${children}</h1>`,
|
|
524
|
+
})}
|
|
525
|
+
/>
|
|
526
|
+
```
|
|
527
|
+
|
|
528
|
+
`.value` è la stringa HTML renderizzata, mentre `String()` / `.toString()` restituiscono il sorgente Markdown non elaborato:
|
|
529
|
+
|
|
530
|
+
```tsx
|
|
531
|
+
myMarkdownContent.value // "<h1>…</h1>"
|
|
532
|
+
String(myMarkdownContent) // "# …"
|
|
533
|
+
myMarkdownContent.toString() // "# …"
|
|
534
|
+
```
|
|
535
|
+
|
|
536
|
+
E puoi accedere ai metadati del tuo markdown in questo modo:
|
|
537
|
+
|
|
538
|
+
```tsx
|
|
539
|
+
myMarkdownContent.metadata
|
|
540
|
+
myMarkdownContent.metadata.title
|
|
541
|
+
```
|
|
542
|
+
|
|
543
|
+
</Tab>
|
|
544
|
+
<Tab label="Astro" value="astro">
|
|
545
|
+
In Astro, i nodi Markdown vengono renderizzati in una stringa HTML. Inseriscila con la direttiva `set:html` nel template o con `innerHTML` in uno `<script>` client.
|
|
546
|
+
|
|
547
|
+
```astro fileName="src/pages/index.astro"
|
|
548
|
+
---
|
|
549
|
+
import { useIntlayer } from "astro-intlayer";
|
|
550
|
+
|
|
551
|
+
const { myMarkdownContent } = useIntlayer("app");
|
|
552
|
+
---
|
|
553
|
+
|
|
554
|
+
<div set:html={myMarkdownContent.value} />
|
|
555
|
+
```
|
|
556
|
+
|
|
557
|
+
```astro fileName="src/components/Content.astro"
|
|
558
|
+
<div id="content"></div>
|
|
559
|
+
|
|
560
|
+
<script>
|
|
561
|
+
import { useIntlayer } from "astro-intlayer";
|
|
562
|
+
|
|
563
|
+
const { myMarkdownContent } = useIntlayer("app");
|
|
564
|
+
|
|
565
|
+
document.querySelector("#content")!.innerHTML = myMarkdownContent.value;
|
|
566
|
+
</script>
|
|
567
|
+
```
|
|
568
|
+
|
|
569
|
+
> Astro esegue l'escape di `{espressioni}` per impostazione predefinita. `set:html` è il meccanismo di esclusione, che è ciò di cui ha bisogno una stringa Markdown renderizzata.
|
|
570
|
+
|
|
571
|
+
Puoi anche fornire override locali per tag specifici utilizzando il metodo `.use()`. Gli override sono funzioni che restituiscono una stringa HTML:
|
|
572
|
+
|
|
573
|
+
```astro
|
|
574
|
+
<div
|
|
575
|
+
set:html={myMarkdownContent.use({
|
|
576
|
+
h1: ({ children }) => `<h1 class="text-3xl font-bold">${children}</h1>`,
|
|
577
|
+
})}
|
|
578
|
+
/>
|
|
579
|
+
```
|
|
580
|
+
|
|
581
|
+
`.value` è la stringa HTML renderizzata, mentre `String()` / `.toString()` restituiscono il sorgente Markdown non elaborato:
|
|
582
|
+
|
|
583
|
+
```astro
|
|
584
|
+
myMarkdownContent.value // "<h1>…</h1>"
|
|
585
|
+
String(myMarkdownContent) // "# …"
|
|
586
|
+
myMarkdownContent.toString() // "# …"
|
|
587
|
+
```
|
|
588
|
+
|
|
589
|
+
E puoi accedere ai metadati del tuo markdown in questo modo:
|
|
590
|
+
|
|
591
|
+
```astro
|
|
592
|
+
myMarkdownContent.metadata
|
|
593
|
+
myMarkdownContent.metadata.title
|
|
594
|
+
```
|
|
595
|
+
|
|
596
|
+
</Tab>
|
|
490
597
|
</Tabs>
|
|
491
598
|
|
|
492
599
|
### 2. Utility di Supporto (Solo Stringhe Markdown)
|
|
@@ -698,6 +805,60 @@ Queste utility eseguono il rendering **solo di stringhe Markdown pure** e sono i
|
|
|
698
805
|
```
|
|
699
806
|
|
|
700
807
|
</Tab>
|
|
808
|
+
<Tab label="Remix" value="remix">
|
|
809
|
+
#### Hook `useMarkdownRenderer()`
|
|
810
|
+
|
|
811
|
+
Ottieni una funzione di rendering preconfigurata da `installIntlayerMarkdown()`. Restituisce una stringa HTML.
|
|
812
|
+
|
|
813
|
+
```tsx
|
|
814
|
+
import { useMarkdownRenderer } from "remix-intlayer/markdown";
|
|
815
|
+
|
|
816
|
+
const renderMarkdown = useMarkdownRenderer({ forceBlock: true });
|
|
817
|
+
|
|
818
|
+
return <div innerHTML={renderMarkdown("# My Title")} />;
|
|
819
|
+
```
|
|
820
|
+
|
|
821
|
+
#### Utility `renderMarkdown()`
|
|
822
|
+
|
|
823
|
+
Utility autonoma che ignora la configurazione globale.
|
|
824
|
+
|
|
825
|
+
```tsx
|
|
826
|
+
import { renderMarkdown } from "remix-intlayer/markdown";
|
|
827
|
+
|
|
828
|
+
const html = renderMarkdown("# My Title", { forceBlock: true });
|
|
829
|
+
```
|
|
830
|
+
|
|
831
|
+
</Tab>
|
|
832
|
+
<Tab label="Astro" value="astro">
|
|
833
|
+
#### Hook `useMarkdownRenderer()`
|
|
834
|
+
|
|
835
|
+
Ottieni una funzione di rendering preconfigurata da `installIntlayerMarkdown()`. Restituisce una stringa HTML.
|
|
836
|
+
|
|
837
|
+
```astro
|
|
838
|
+
---
|
|
839
|
+
import { useMarkdownRenderer } from "astro-intlayer/markdown";
|
|
840
|
+
|
|
841
|
+
const renderMarkdown = useMarkdownRenderer({ forceBlock: true });
|
|
842
|
+
---
|
|
843
|
+
|
|
844
|
+
<div set:html={renderMarkdown("# My Title")} />
|
|
845
|
+
```
|
|
846
|
+
|
|
847
|
+
#### Utility `renderMarkdown()`
|
|
848
|
+
|
|
849
|
+
Utility autonoma che ignora la configurazione globale.
|
|
850
|
+
|
|
851
|
+
```astro
|
|
852
|
+
---
|
|
853
|
+
import { renderMarkdown } from "astro-intlayer/markdown";
|
|
854
|
+
|
|
855
|
+
const html = renderMarkdown("# My Title", { forceBlock: true });
|
|
856
|
+
---
|
|
857
|
+
|
|
858
|
+
<div set:html={html} />
|
|
859
|
+
```
|
|
860
|
+
|
|
861
|
+
</Tab>
|
|
701
862
|
</Tabs>
|
|
702
863
|
|
|
703
864
|
## Configurazione Globale con `MarkdownProvider`
|
|
@@ -998,6 +1159,73 @@ Puoi anche usare il tuo markdown renderer personalizzato:
|
|
|
998
1159
|
> Importare dinamicamente il tuo renderer Markdown è un buon modo per ridurre le dimensioni del bundle della tua applicazione.
|
|
999
1160
|
|
|
1000
1161
|
</Tab>
|
|
1162
|
+
<Tab label="Remix" value="remix">
|
|
1163
|
+
|
|
1164
|
+
Remix non ha un albero dei componenti per contenere un provider, quindi la configurazione viene installata una sola volta, come singleton, all'avvio del server. Configura il renderer restituito da `useMarkdownRenderer()`. I nodi `md` restituiti da `useIntlayer` vengono renderizzati con il compilatore predefinito; sovrascrivi i loro tag per nodo con `.use()`.
|
|
1165
|
+
|
|
1166
|
+
```typescript fileName="src/router.ts"
|
|
1167
|
+
import { installIntlayerMarkdown } from "remix-intlayer/markdown";
|
|
1168
|
+
|
|
1169
|
+
installIntlayerMarkdown({
|
|
1170
|
+
forceBlock: true,
|
|
1171
|
+
components: {
|
|
1172
|
+
h1: ({ children }) => `<h1 class="text-2xl font-bold">${children}</h1>`,
|
|
1173
|
+
},
|
|
1174
|
+
});
|
|
1175
|
+
```
|
|
1176
|
+
|
|
1177
|
+
Puoi anche utilizzare il tuo renderer markdown:
|
|
1178
|
+
|
|
1179
|
+
```typescript fileName="src/router.ts"
|
|
1180
|
+
import { installIntlayerMarkdown } from "remix-intlayer/markdown";
|
|
1181
|
+
|
|
1182
|
+
installIntlayerMarkdown({
|
|
1183
|
+
renderMarkdown: async (md) => {
|
|
1184
|
+
const { marked } = await import("marked");
|
|
1185
|
+
return marked(md) as string;
|
|
1186
|
+
},
|
|
1187
|
+
});
|
|
1188
|
+
```
|
|
1189
|
+
|
|
1190
|
+
> Usa `installIntlayerMarkdownDynamic(async () => …)` per caricare il renderer in modo lazy; il loader viene eseguito solo alla prima chiamata.
|
|
1191
|
+
|
|
1192
|
+
</Tab>
|
|
1193
|
+
<Tab label="Astro" value="astro">
|
|
1194
|
+
|
|
1195
|
+
Astro non ha un albero dei componenti per contenere un provider, quindi la configurazione viene installata una sola volta, come singleton, nel middleware (server) e in uno `<script>` client (browser). Configura il renderer restituito da `useMarkdownRenderer()`. I nodi `md` restituiti da `useIntlayer` vengono renderizzati con il compilatore predefinito; sovrascrivi i loro tag per nodo con `.use()`.
|
|
1196
|
+
|
|
1197
|
+
```typescript fileName="src/middleware.ts"
|
|
1198
|
+
import { installIntlayerMarkdown } from "astro-intlayer/markdown";
|
|
1199
|
+
import { defineMiddleware } from "astro:middleware";
|
|
1200
|
+
|
|
1201
|
+
// Viene eseguito una sola volta all'avvio del server; il middleware Intlayer stesso è
|
|
1202
|
+
// registrato dall'integrazione, prima di questo file.
|
|
1203
|
+
installIntlayerMarkdown({
|
|
1204
|
+
forceBlock: true,
|
|
1205
|
+
components: {
|
|
1206
|
+
h1: ({ children }) => `<h1 class="text-2xl font-bold">${children}</h1>`,
|
|
1207
|
+
},
|
|
1208
|
+
});
|
|
1209
|
+
|
|
1210
|
+
export const onRequest = defineMiddleware((_context, next) => next());
|
|
1211
|
+
```
|
|
1212
|
+
|
|
1213
|
+
Puoi anche utilizzare il tuo renderer markdown:
|
|
1214
|
+
|
|
1215
|
+
```typescript fileName="src/middleware.ts"
|
|
1216
|
+
import { installIntlayerMarkdown } from "astro-intlayer/markdown";
|
|
1217
|
+
|
|
1218
|
+
installIntlayerMarkdown({
|
|
1219
|
+
renderMarkdown: async (md) => {
|
|
1220
|
+
const { marked } = await import("marked");
|
|
1221
|
+
return marked(md) as string;
|
|
1222
|
+
},
|
|
1223
|
+
});
|
|
1224
|
+
```
|
|
1225
|
+
|
|
1226
|
+
> Usa `installIntlayerMarkdownDynamic(async () => …)` per caricare il renderer in modo lazy; il loader viene eseguito solo alla prima chiamata.
|
|
1227
|
+
|
|
1228
|
+
</Tab>
|
|
1001
1229
|
</Tabs>
|
|
1002
1230
|
|
|
1003
1231
|
## Suspense
|
|
@@ -1326,6 +1554,40 @@ Invece di inviare stringhe Markdown grezze al client e analizzarle nel browser (
|
|
|
1326
1554
|
```
|
|
1327
1555
|
|
|
1328
1556
|
</Tab>
|
|
1557
|
+
<Tab label="Remix" value="remix">
|
|
1558
|
+
|
|
1559
|
+
Remix 3 esegue il rendering sul server e trasmette l'HTML in streaming, quindi nessun AST deve raggiungere il client. Esegui il parsing una volta e renderizza l'AST ovunque venga creata la pagina:
|
|
1560
|
+
|
|
1561
|
+
```tsx fileName="src/views/article.tsx"
|
|
1562
|
+
import { parseMarkdown, renderMarkdown } from "remix-intlayer/markdown";
|
|
1563
|
+
|
|
1564
|
+
// 1. Esegui il parsing del markdown in un AST serializzabile (es. una volta, al caricamento del modulo)
|
|
1565
|
+
const ast = parseMarkdown("## My title \n\nLorem Ipsum");
|
|
1566
|
+
|
|
1567
|
+
export const ArticlePage = () => () => (
|
|
1568
|
+
// 2. Renderizza l'AST: il renderer accetta una stringa non elaborata o l'AST analizzato
|
|
1569
|
+
<article innerHTML={renderMarkdown(ast)} />
|
|
1570
|
+
);
|
|
1571
|
+
```
|
|
1572
|
+
|
|
1573
|
+
</Tab>
|
|
1574
|
+
<Tab label="Astro" value="astro">
|
|
1575
|
+
|
|
1576
|
+
Le pagine Astro vengono renderizzate sul server, quindi nessun AST deve raggiungere il client. Esegui il parsing del Markdown nel frontmatter e renderizzalo con `set:html`:
|
|
1577
|
+
|
|
1578
|
+
```astro fileName="src/pages/article.astro"
|
|
1579
|
+
---
|
|
1580
|
+
import { parseMarkdown, renderMarkdown } from "astro-intlayer/markdown";
|
|
1581
|
+
|
|
1582
|
+
// 1. Esegui il parsing del markdown in un AST serializzabile
|
|
1583
|
+
const ast = parseMarkdown("## My title \n\nLorem Ipsum");
|
|
1584
|
+
---
|
|
1585
|
+
|
|
1586
|
+
<!-- 2. Renderizza l'AST: il renderer accetta una stringa non elaborata o l'AST analizzato -->
|
|
1587
|
+
<article set:html={renderMarkdown(ast)} />
|
|
1588
|
+
```
|
|
1589
|
+
|
|
1590
|
+
</Tab>
|
|
1329
1591
|
</Tabs>
|
|
1330
1592
|
|
|
1331
1593
|
Questo modello garantisce che la logica di analisi del Markdown venga eseguita interamente sul server, riducendo significativamente il tempo di esecuzione lato client e migliorando la velocità di idratazione iniziale.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
createdAt: 2025-04-18
|
|
3
|
-
updatedAt: 2026-
|
|
3
|
+
updatedAt: 2026-09-21
|
|
4
4
|
title: "Analog i18n - Guida completa per tradurre la tua applicazione"
|
|
5
5
|
description: "Niente più i18next. La guida 2026 per creare un'applicazione Analog multilingue (i18n). Traduci con agenti AI e ottimizza la dimensione del bundle, SEO e prestazioni."
|
|
6
6
|
keywords:
|
|
@@ -157,6 +157,28 @@ bun add intlayer angular-intlayer vite-intlayer
|
|
|
157
157
|
</Step>
|
|
158
158
|
<Step number={2} title="Configurazione del tuo Progetto">
|
|
159
159
|
|
|
160
|
+
### Architettura
|
|
161
|
+
|
|
162
|
+
In questa architettura, `angular-intlayer` fornisce `provideIntlayer()`, registrato in `src/app/app.config.ts` in modo che ogni componente e pagina basata su file possa leggere il proprio contenuto tramite il segnale `useIntlayer`. Analog è basato su Vite, quindi il plugin `intlayer()` di `vite-intlayer` viene aggiunto accanto ad `analog()` in `vite.config.ts` per monitorare e ricostruire le dichiarazioni di contenuto ed eseguire il proxy della locale. Le dichiarazioni di contenuto sono posizionate accanto ai componenti e alle pagine in `src/app/`.
|
|
163
|
+
|
|
164
|
+
```bash
|
|
165
|
+
.
|
|
166
|
+
├── src
|
|
167
|
+
│ ├── app
|
|
168
|
+
│ │ ├── pages
|
|
169
|
+
│ │ │ └── index.page.ts # File-based route using useIntlayer
|
|
170
|
+
│ │ ├── app.config.ts # Application config with provideIntlayer()
|
|
171
|
+
│ │ ├── app.content.ts # App content declaration
|
|
172
|
+
│ │ └── locale-switcher.component.ts
|
|
173
|
+
│ └── main.ts
|
|
174
|
+
├── intlayer.config.ts
|
|
175
|
+
├── package.json
|
|
176
|
+
├── tsconfig.json
|
|
177
|
+
└── vite.config.ts # analog() and intlayer() Vite plugins
|
|
178
|
+
```
|
|
179
|
+
|
|
180
|
+
### Configurazione
|
|
181
|
+
|
|
160
182
|
Crea un file di configurazione per configurare le lingue della tua applicazione:
|
|
161
183
|
|
|
162
184
|
```typescript fileName="intlayer.config.ts" codeFormat={["typescript", "esm", "commonjs"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
createdAt: 2025-04-18
|
|
3
|
-
updatedAt: 2026-
|
|
3
|
+
updatedAt: 2026-09-21
|
|
4
4
|
title: "Angular 19 i18n - Guida completa per tradurre la tua applicazione"
|
|
5
5
|
description: "Niente più i18next. La guida 2026 per creare un'applicazione Angular 19 multilingue (i18n). Traduci con agenti AI e ottimizza la dimensione del bundle, SEO e prestazioni."
|
|
6
6
|
keywords:
|
|
@@ -164,6 +164,29 @@ bun add @angular-builders/custom-webpack --dev
|
|
|
164
164
|
</Step>
|
|
165
165
|
<Step number={2} title="Configurazione del progetto">
|
|
166
166
|
|
|
167
|
+
### Architettura
|
|
168
|
+
|
|
169
|
+
In questa architettura, `angular-intlayer` fornisce `provideIntlayer()`, registrato in `src/app/app.config.ts` in modo che ogni componente possa leggere il proprio contenuto tramite il segnale `useIntlayer`. La CLI di Angular viene configurata con il builder Webpack personalizzato, e `webpack.config.ts` unisce il plugin Intlayer nella build per monitorare e ricostruire le dichiarazioni di contenuto. Le dichiarazioni di contenuto sono posizionate accanto ai componenti in `src/app/`.
|
|
170
|
+
|
|
171
|
+
```bash
|
|
172
|
+
.
|
|
173
|
+
├── src
|
|
174
|
+
│ ├── app
|
|
175
|
+
│ │ ├── app.component.html # Root template reading the content signal
|
|
176
|
+
│ │ ├── app.component.ts # Root component using useIntlayer
|
|
177
|
+
│ │ ├── app.config.ts # Application config with provideIntlayer()
|
|
178
|
+
│ │ ├── app.content.ts # App content declaration
|
|
179
|
+
│ │ └── locale-switcher.component.ts
|
|
180
|
+
│ └── main.ts
|
|
181
|
+
├── angular.json # Custom Webpack builder for build and serve
|
|
182
|
+
├── intlayer.config.ts
|
|
183
|
+
├── package.json
|
|
184
|
+
├── tsconfig.json
|
|
185
|
+
└── webpack.config.ts # mergeConfig() from angular-intlayer/webpack
|
|
186
|
+
```
|
|
187
|
+
|
|
188
|
+
### Configurazione
|
|
189
|
+
|
|
167
190
|
Crea un file di configurazione per impostare le lingue della tua applicazione:
|
|
168
191
|
|
|
169
192
|
```typescript fileName="intlayer.config.ts" codeFormat={["typescript", "esm", "commonjs"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
createdAt: 2025-04-18
|
|
3
|
-
updatedAt: 2026-
|
|
3
|
+
updatedAt: 2026-09-21
|
|
4
4
|
title: "Angular 22 i18n - Guida completa per tradurre la tua applicazione"
|
|
5
5
|
description: "Niente più i18next. La guida 2026 per creare un'applicazione Angular 22 multilingue (i18n). Traduci con agenti AI e ottimizza la dimensione del bundle, SEO e prestazioni."
|
|
6
6
|
keywords:
|
|
@@ -166,6 +166,29 @@ bun add @angular-builders/custom-esbuild --dev
|
|
|
166
166
|
</Step>
|
|
167
167
|
<Step number={2} title="Configurazione del tuo progetto">
|
|
168
168
|
|
|
169
|
+
### Architettura
|
|
170
|
+
|
|
171
|
+
In questa architettura, `angular-intlayer` fornisce `provideIntlayer()`, registrato in `src/app/app.config.ts` in modo che ogni componente possa leggere il proprio contenuto tramite il segnale `useIntlayer`. La CLI di Angular viene configurata con il builder esbuild personalizzato, e `esbuild.plugins.ts` registra il plugin Intlayer nella build per monitorare e ricostruire le dichiarazioni di contenuto. Le dichiarazioni di contenuto sono posizionate accanto ai componenti in `src/app/`.
|
|
172
|
+
|
|
173
|
+
```bash
|
|
174
|
+
.
|
|
175
|
+
├── src
|
|
176
|
+
│ ├── app
|
|
177
|
+
│ │ ├── app.component.html # Root template reading the content signal
|
|
178
|
+
│ │ ├── app.component.ts # Root component using useIntlayer
|
|
179
|
+
│ │ ├── app.config.ts # Application config with provideIntlayer()
|
|
180
|
+
│ │ ├── app.content.ts # App content declaration
|
|
181
|
+
│ │ └── locale-switcher.component.ts
|
|
182
|
+
│ └── main.ts
|
|
183
|
+
├── angular.json # Custom esbuild builder for build and serve
|
|
184
|
+
├── esbuild.plugins.ts # intlayerEsbuildPlugin() from angular-intlayer/esbuild
|
|
185
|
+
├── intlayer.config.ts
|
|
186
|
+
├── package.json
|
|
187
|
+
└── tsconfig.json
|
|
188
|
+
```
|
|
189
|
+
|
|
190
|
+
### Configurazione
|
|
191
|
+
|
|
169
192
|
Crea un file di configurazione per impostare le lingue della tua applicazione:
|
|
170
193
|
|
|
171
194
|
```typescript fileName="intlayer.config.ts" codeFormat={["typescript", "esm", "commonjs"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
createdAt: 2024-03-07
|
|
3
|
-
updatedAt: 2026-09-
|
|
3
|
+
updatedAt: 2026-09-21
|
|
4
4
|
title: "Astro i18n - Guida completa per tradurre la tua applicazione"
|
|
5
5
|
description: "Niente più i18next. La guida 2026 per creare un'applicazione Astro multilingue (i18n). Traduci con agenti AI e ottimizza la dimensione del bundle, SEO e prestazioni."
|
|
6
6
|
keywords:
|
|
@@ -160,6 +160,29 @@ bun add intlayer astro-intlayer
|
|
|
160
160
|
</Step>
|
|
161
161
|
<Step number={2} title="Configura il tuo progetto">
|
|
162
162
|
|
|
163
|
+
### Architettura
|
|
164
|
+
|
|
165
|
+
In questa architettura, l'integrazione `intlayer()` registrata in `astro.config.ts` compila i tuoi dizionari e aggiunge un middleware che risolve la locale di ogni richiesta esponendola su `Astro.locals.intlayer`. Le pagine si trovano sotto un segmento rest `src/pages/[...locale]/`, in modo che la locale predefinita venga servita senza prefisso e ogni altra locale ottenga il proprio URL dedicato. I file `.astro` leggono il contenuto con gli hook `useIntlayer` / `useLocale` di `astro-intlayer`, e le dichiarazioni di contenuto sono posizionate accanto ai tuoi componenti in `src/`.
|
|
166
|
+
|
|
167
|
+
```bash
|
|
168
|
+
.
|
|
169
|
+
├── src
|
|
170
|
+
│ ├── app.content.tsx # App content declaration
|
|
171
|
+
│ ├── components
|
|
172
|
+
│ │ └── LocaleSwitcher.astro # Locale switcher component
|
|
173
|
+
│ └── pages
|
|
174
|
+
│ ├── [...locale]
|
|
175
|
+
│ │ └── index.astro # Localized page (rest param also serves the default locale)
|
|
176
|
+
│ ├── robots.txt.ts # robots.txt endpoint
|
|
177
|
+
│ └── sitemap.xml.ts # Localized sitemap endpoint
|
|
178
|
+
├── astro.config.ts # Astro config with the intlayer() integration
|
|
179
|
+
├── intlayer.config.ts
|
|
180
|
+
├── package.json
|
|
181
|
+
└── tsconfig.json
|
|
182
|
+
```
|
|
183
|
+
|
|
184
|
+
### Configurazione
|
|
185
|
+
|
|
163
186
|
Crea un file di configurazione per definire le lingue della tua applicazione:
|
|
164
187
|
|
|
165
188
|
```typescript fileName="intlayer.config.ts"
|