@intlayer/docs 7.5.8 → 7.5.10

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.
Files changed (529) hide show
  1. package/README.md +9 -2
  2. package/dist/cjs/generated/docs.entry.cjs +38 -0
  3. package/dist/cjs/generated/docs.entry.cjs.map +1 -1
  4. package/dist/esm/generated/docs.entry.mjs +38 -0
  5. package/dist/esm/generated/docs.entry.mjs.map +1 -1
  6. package/dist/types/generated/docs.entry.d.ts +2 -0
  7. package/dist/types/generated/docs.entry.d.ts.map +1 -1
  8. package/docs/ar/cli/index.md +6 -1
  9. package/docs/ar/cli/init.md +84 -0
  10. package/docs/ar/cli/push.md +1 -1
  11. package/docs/ar/configuration.md +3 -3
  12. package/docs/ar/interest_of_intlayer.md +1 -1
  13. package/docs/ar/intlayer_CMS.md +5 -5
  14. package/docs/ar/intlayer_with_angular.md +5 -2
  15. package/docs/ar/intlayer_with_astro.md +5 -2
  16. package/docs/ar/intlayer_with_create_react_app.md +5 -2
  17. package/docs/ar/intlayer_with_express.md +6 -2
  18. package/docs/ar/intlayer_with_fastify.md +516 -0
  19. package/docs/ar/intlayer_with_lynx+react.md +5 -2
  20. package/docs/ar/intlayer_with_nestjs.md +5 -2
  21. package/docs/ar/intlayer_with_next-i18next.md +1 -1
  22. package/docs/ar/intlayer_with_next-intl.md +1 -1
  23. package/docs/ar/intlayer_with_nextjs_14.md +1 -1
  24. package/docs/ar/intlayer_with_nextjs_15.md +5 -2
  25. package/docs/ar/intlayer_with_nextjs_16.md +5 -2
  26. package/docs/ar/intlayer_with_nextjs_page_router.md +5 -2
  27. package/docs/ar/intlayer_with_nuxt.md +1 -1
  28. package/docs/ar/intlayer_with_react_native+expo.md +5 -2
  29. package/docs/ar/intlayer_with_react_router_v7.md +5 -2
  30. package/docs/ar/intlayer_with_react_router_v7_fs_routes.md +5 -2
  31. package/docs/ar/intlayer_with_svelte_kit.md +5 -2
  32. package/docs/ar/intlayer_with_tanstack.md +5 -2
  33. package/docs/ar/intlayer_with_vite+preact.md +5 -2
  34. package/docs/ar/intlayer_with_vite+react.md +5 -2
  35. package/docs/ar/intlayer_with_vite+solid.md +5 -2
  36. package/docs/ar/intlayer_with_vite+svelte.md +5 -2
  37. package/docs/ar/intlayer_with_vite+vue.md +5 -2
  38. package/docs/ar/readme.md +1 -1
  39. package/docs/de/cli/index.md +6 -1
  40. package/docs/de/cli/init.md +92 -0
  41. package/docs/de/cli/push.md +1 -1
  42. package/docs/de/configuration.md +3 -3
  43. package/docs/de/interest_of_intlayer.md +1 -1
  44. package/docs/de/intlayer_CMS.md +5 -5
  45. package/docs/de/intlayer_with_angular.md +5 -2
  46. package/docs/de/intlayer_with_astro.md +5 -2
  47. package/docs/de/intlayer_with_create_react_app.md +1 -1
  48. package/docs/de/intlayer_with_express.md +6 -2
  49. package/docs/de/intlayer_with_fastify.md +449 -0
  50. package/docs/de/intlayer_with_lynx+react.md +5 -2
  51. package/docs/de/intlayer_with_nestjs.md +5 -2
  52. package/docs/de/intlayer_with_next-i18next.md +1 -1
  53. package/docs/de/intlayer_with_next-intl.md +1 -1
  54. package/docs/de/intlayer_with_nextjs_14.md +1 -1
  55. package/docs/de/intlayer_with_nextjs_15.md +5 -2
  56. package/docs/de/intlayer_with_nextjs_16.md +5 -2
  57. package/docs/de/intlayer_with_nextjs_page_router.md +5 -2
  58. package/docs/de/intlayer_with_nuxt.md +1 -1
  59. package/docs/de/intlayer_with_react_native+expo.md +5 -2
  60. package/docs/de/intlayer_with_react_router_v7.md +5 -2
  61. package/docs/de/intlayer_with_react_router_v7_fs_routes.md +5 -2
  62. package/docs/de/intlayer_with_svelte_kit.md +5 -2
  63. package/docs/de/intlayer_with_tanstack.md +5 -2
  64. package/docs/de/intlayer_with_vite+preact.md +5 -2
  65. package/docs/de/intlayer_with_vite+react.md +5 -2
  66. package/docs/de/intlayer_with_vite+solid.md +5 -2
  67. package/docs/de/intlayer_with_vite+svelte.md +5 -2
  68. package/docs/de/intlayer_with_vite+vue.md +5 -2
  69. package/docs/de/readme.md +1 -1
  70. package/docs/en/cli/index.md +6 -1
  71. package/docs/en/cli/init.md +84 -0
  72. package/docs/en/cli/push.md +1 -1
  73. package/docs/en/configuration.md +3 -3
  74. package/docs/en/interest_of_intlayer.md +1 -1
  75. package/docs/en/intlayer_CMS.md +5 -5
  76. package/docs/en/intlayer_with_angular.md +5 -2
  77. package/docs/en/intlayer_with_astro.md +5 -2
  78. package/docs/en/intlayer_with_create_react_app.md +5 -2
  79. package/docs/en/intlayer_with_express.md +6 -2
  80. package/docs/en/intlayer_with_fastify.md +439 -0
  81. package/docs/en/intlayer_with_lynx+react.md +5 -2
  82. package/docs/en/intlayer_with_nestjs.md +5 -2
  83. package/docs/en/intlayer_with_next-i18next.md +1 -1
  84. package/docs/en/intlayer_with_next-intl.md +1 -1
  85. package/docs/en/intlayer_with_nextjs_14.md +5 -2
  86. package/docs/en/intlayer_with_nextjs_15.md +5 -2
  87. package/docs/en/intlayer_with_nextjs_16.md +5 -2
  88. package/docs/en/intlayer_with_nextjs_page_router.md +5 -2
  89. package/docs/en/intlayer_with_nuxt.md +5 -2
  90. package/docs/en/intlayer_with_react_native+expo.md +5 -2
  91. package/docs/en/intlayer_with_react_router_v7.md +5 -2
  92. package/docs/en/intlayer_with_react_router_v7_fs_routes.md +5 -2
  93. package/docs/en/intlayer_with_svelte_kit.md +5 -2
  94. package/docs/en/intlayer_with_tanstack.md +5 -2
  95. package/docs/en/intlayer_with_vite+preact.md +5 -2
  96. package/docs/en/intlayer_with_vite+react.md +5 -2
  97. package/docs/en/intlayer_with_vite+solid.md +5 -2
  98. package/docs/en/intlayer_with_vite+svelte.md +5 -2
  99. package/docs/en/intlayer_with_vite+vue.md +5 -2
  100. package/docs/en/readme.md +3 -1
  101. package/docs/en-GB/cli/index.md +6 -1
  102. package/docs/en-GB/cli/init.md +89 -0
  103. package/docs/en-GB/cli/push.md +1 -1
  104. package/docs/en-GB/configuration.md +3 -3
  105. package/docs/en-GB/interest_of_intlayer.md +1 -1
  106. package/docs/en-GB/intlayer_CMS.md +5 -5
  107. package/docs/en-GB/intlayer_with_angular.md +5 -2
  108. package/docs/en-GB/intlayer_with_astro.md +5 -2
  109. package/docs/en-GB/intlayer_with_create_react_app.md +5 -2
  110. package/docs/en-GB/intlayer_with_express.md +6 -2
  111. package/docs/en-GB/intlayer_with_fastify.md +445 -0
  112. package/docs/en-GB/intlayer_with_lynx+react.md +5 -2
  113. package/docs/en-GB/intlayer_with_nestjs.md +5 -2
  114. package/docs/en-GB/intlayer_with_next-i18next.md +1 -1
  115. package/docs/en-GB/intlayer_with_next-intl.md +1 -1
  116. package/docs/en-GB/intlayer_with_nextjs_14.md +5 -2
  117. package/docs/en-GB/intlayer_with_nextjs_15.md +5 -2
  118. package/docs/en-GB/intlayer_with_nextjs_16.md +5 -2
  119. package/docs/en-GB/intlayer_with_nextjs_page_router.md +5 -2
  120. package/docs/en-GB/intlayer_with_nuxt.md +1 -1
  121. package/docs/en-GB/intlayer_with_react_native+expo.md +5 -2
  122. package/docs/en-GB/intlayer_with_react_router_v7.md +5 -2
  123. package/docs/en-GB/intlayer_with_react_router_v7_fs_routes.md +5 -2
  124. package/docs/en-GB/intlayer_with_svelte_kit.md +5 -2
  125. package/docs/en-GB/intlayer_with_tanstack.md +5 -2
  126. package/docs/en-GB/intlayer_with_vite+preact.md +5 -2
  127. package/docs/en-GB/intlayer_with_vite+react.md +5 -2
  128. package/docs/en-GB/intlayer_with_vite+solid.md +5 -2
  129. package/docs/en-GB/intlayer_with_vite+svelte.md +5 -2
  130. package/docs/en-GB/intlayer_with_vite+vue.md +5 -2
  131. package/docs/en-GB/readme.md +3 -1
  132. package/docs/es/cli/index.md +6 -1
  133. package/docs/es/cli/init.md +84 -0
  134. package/docs/es/cli/push.md +1 -1
  135. package/docs/es/configuration.md +3 -3
  136. package/docs/es/interest_of_intlayer.md +1 -1
  137. package/docs/es/intlayer_CMS.md +5 -5
  138. package/docs/es/intlayer_with_angular.md +5 -2
  139. package/docs/es/intlayer_with_astro.md +5 -2
  140. package/docs/es/intlayer_with_create_react_app.md +5 -2
  141. package/docs/es/intlayer_with_express.md +6 -2
  142. package/docs/es/intlayer_with_fastify.md +480 -0
  143. package/docs/es/intlayer_with_lynx+react.md +5 -2
  144. package/docs/es/intlayer_with_nestjs.md +5 -2
  145. package/docs/es/intlayer_with_next-i18next.md +1 -1
  146. package/docs/es/intlayer_with_next-intl.md +1 -1
  147. package/docs/es/intlayer_with_nextjs_14.md +5 -2
  148. package/docs/es/intlayer_with_nextjs_15.md +5 -2
  149. package/docs/es/intlayer_with_nextjs_16.md +5 -2
  150. package/docs/es/intlayer_with_nextjs_page_router.md +5 -2
  151. package/docs/es/intlayer_with_nuxt.md +1 -1
  152. package/docs/es/intlayer_with_react_native+expo.md +5 -2
  153. package/docs/es/intlayer_with_react_router_v7.md +5 -2
  154. package/docs/es/intlayer_with_react_router_v7_fs_routes.md +5 -2
  155. package/docs/es/intlayer_with_svelte_kit.md +5 -2
  156. package/docs/es/intlayer_with_tanstack.md +5 -2
  157. package/docs/es/intlayer_with_vite+preact.md +5 -2
  158. package/docs/es/intlayer_with_vite+react.md +5 -2
  159. package/docs/es/intlayer_with_vite+solid.md +5 -2
  160. package/docs/es/intlayer_with_vite+svelte.md +5 -2
  161. package/docs/es/intlayer_with_vite+vue.md +5 -2
  162. package/docs/es/readme.md +1 -1
  163. package/docs/fr/cli/index.md +6 -1
  164. package/docs/fr/cli/init.md +84 -0
  165. package/docs/fr/cli/push.md +1 -1
  166. package/docs/fr/configuration.md +3 -3
  167. package/docs/fr/interest_of_intlayer.md +1 -1
  168. package/docs/fr/intlayer_CMS.md +5 -5
  169. package/docs/fr/intlayer_with_angular.md +5 -2
  170. package/docs/fr/intlayer_with_astro.md +5 -2
  171. package/docs/fr/intlayer_with_create_react_app.md +5 -2
  172. package/docs/fr/intlayer_with_express.md +6 -2
  173. package/docs/fr/intlayer_with_fastify.md +439 -0
  174. package/docs/fr/intlayer_with_lynx+react.md +5 -2
  175. package/docs/fr/intlayer_with_nestjs.md +5 -2
  176. package/docs/fr/intlayer_with_next-i18next.md +1 -1
  177. package/docs/fr/intlayer_with_next-intl.md +1 -1
  178. package/docs/fr/intlayer_with_nextjs_14.md +1 -1
  179. package/docs/fr/intlayer_with_nextjs_15.md +5 -2
  180. package/docs/fr/intlayer_with_nextjs_16.md +5 -2
  181. package/docs/fr/intlayer_with_nextjs_page_router.md +5 -2
  182. package/docs/fr/intlayer_with_nuxt.md +1 -1
  183. package/docs/fr/intlayer_with_react_native+expo.md +5 -2
  184. package/docs/fr/intlayer_with_react_router_v7.md +5 -2
  185. package/docs/fr/intlayer_with_react_router_v7_fs_routes.md +5 -2
  186. package/docs/fr/intlayer_with_svelte_kit.md +5 -2
  187. package/docs/fr/intlayer_with_tanstack.md +5 -2
  188. package/docs/fr/intlayer_with_vite+preact.md +5 -2
  189. package/docs/fr/intlayer_with_vite+react.md +5 -2
  190. package/docs/fr/intlayer_with_vite+solid.md +5 -2
  191. package/docs/fr/intlayer_with_vite+svelte.md +5 -2
  192. package/docs/fr/intlayer_with_vite+vue.md +5 -2
  193. package/docs/fr/readme.md +1 -1
  194. package/docs/hi/cli/index.md +6 -1
  195. package/docs/hi/cli/init.md +92 -0
  196. package/docs/hi/cli/push.md +1 -1
  197. package/docs/hi/configuration.md +3 -3
  198. package/docs/hi/interest_of_intlayer.md +1 -1
  199. package/docs/hi/intlayer_CMS.md +5 -5
  200. package/docs/hi/intlayer_with_angular.md +5 -2
  201. package/docs/hi/intlayer_with_astro.md +5 -2
  202. package/docs/hi/intlayer_with_create_react_app.md +1 -1
  203. package/docs/hi/intlayer_with_express.md +6 -2
  204. package/docs/hi/intlayer_with_fastify.md +540 -0
  205. package/docs/hi/intlayer_with_lynx+react.md +5 -2
  206. package/docs/hi/intlayer_with_nestjs.md +5 -2
  207. package/docs/hi/intlayer_with_next-i18next.md +1 -1
  208. package/docs/hi/intlayer_with_next-intl.md +1 -1
  209. package/docs/hi/intlayer_with_nextjs_14.md +1 -1
  210. package/docs/hi/intlayer_with_nextjs_15.md +5 -2
  211. package/docs/hi/intlayer_with_nextjs_16.md +5 -2
  212. package/docs/hi/intlayer_with_nextjs_page_router.md +5 -2
  213. package/docs/hi/intlayer_with_nuxt.md +1 -1
  214. package/docs/hi/intlayer_with_react_native+expo.md +5 -2
  215. package/docs/hi/intlayer_with_react_router_v7.md +5 -2
  216. package/docs/hi/intlayer_with_react_router_v7_fs_routes.md +5 -2
  217. package/docs/hi/intlayer_with_svelte_kit.md +5 -2
  218. package/docs/hi/intlayer_with_tanstack.md +5 -2
  219. package/docs/hi/intlayer_with_vite+preact.md +5 -2
  220. package/docs/hi/intlayer_with_vite+react.md +5 -2
  221. package/docs/hi/intlayer_with_vite+solid.md +5 -2
  222. package/docs/hi/intlayer_with_vite+svelte.md +5 -2
  223. package/docs/hi/intlayer_with_vite+vue.md +5 -2
  224. package/docs/hi/readme.md +1 -1
  225. package/docs/id/cli/index.md +6 -1
  226. package/docs/id/cli/init.md +89 -0
  227. package/docs/id/cli/push.md +1 -1
  228. package/docs/id/configuration.md +3 -3
  229. package/docs/id/interest_of_intlayer.md +1 -1
  230. package/docs/id/intlayer_CMS.md +5 -5
  231. package/docs/id/intlayer_with_angular.md +5 -2
  232. package/docs/id/intlayer_with_astro.md +5 -2
  233. package/docs/id/intlayer_with_create_react_app.md +5 -2
  234. package/docs/id/intlayer_with_express.md +6 -2
  235. package/docs/id/intlayer_with_fastify.md +470 -0
  236. package/docs/id/intlayer_with_lynx+react.md +5 -2
  237. package/docs/id/intlayer_with_nestjs.md +5 -2
  238. package/docs/id/intlayer_with_next-i18next.md +1 -1
  239. package/docs/id/intlayer_with_next-intl.md +1 -1
  240. package/docs/id/intlayer_with_nextjs_14.md +5 -2
  241. package/docs/id/intlayer_with_nextjs_15.md +5 -2
  242. package/docs/id/intlayer_with_nextjs_16.md +5 -2
  243. package/docs/id/intlayer_with_nextjs_page_router.md +5 -2
  244. package/docs/id/intlayer_with_nuxt.md +1 -1
  245. package/docs/id/intlayer_with_react_native+expo.md +5 -2
  246. package/docs/id/intlayer_with_react_router_v7.md +5 -2
  247. package/docs/id/intlayer_with_react_router_v7_fs_routes.md +5 -2
  248. package/docs/id/intlayer_with_svelte_kit.md +5 -2
  249. package/docs/id/intlayer_with_tanstack.md +5 -2
  250. package/docs/id/intlayer_with_vite+preact.md +5 -2
  251. package/docs/id/intlayer_with_vite+react.md +5 -2
  252. package/docs/id/intlayer_with_vite+solid.md +5 -2
  253. package/docs/id/intlayer_with_vite+svelte.md +5 -2
  254. package/docs/id/intlayer_with_vite+vue.md +5 -2
  255. package/docs/id/readme.md +1 -1
  256. package/docs/it/cli/index.md +6 -1
  257. package/docs/it/cli/init.md +97 -0
  258. package/docs/it/cli/push.md +1 -1
  259. package/docs/it/configuration.md +3 -3
  260. package/docs/it/interest_of_intlayer.md +1 -1
  261. package/docs/it/intlayer_CMS.md +5 -5
  262. package/docs/it/intlayer_with_angular.md +5 -2
  263. package/docs/it/intlayer_with_astro.md +5 -2
  264. package/docs/it/intlayer_with_create_react_app.md +5 -2
  265. package/docs/it/intlayer_with_express.md +6 -2
  266. package/docs/it/intlayer_with_fastify.md +445 -0
  267. package/docs/it/intlayer_with_lynx+react.md +5 -2
  268. package/docs/it/intlayer_with_nestjs.md +5 -2
  269. package/docs/it/intlayer_with_next-i18next.md +1 -1
  270. package/docs/it/intlayer_with_next-intl.md +1 -1
  271. package/docs/it/intlayer_with_nextjs_14.md +1 -1
  272. package/docs/it/intlayer_with_nextjs_15.md +5 -2
  273. package/docs/it/intlayer_with_nextjs_16.md +5 -2
  274. package/docs/it/intlayer_with_nextjs_page_router.md +5 -2
  275. package/docs/it/intlayer_with_nuxt.md +1 -1
  276. package/docs/it/intlayer_with_react_native+expo.md +5 -2
  277. package/docs/it/intlayer_with_react_router_v7.md +5 -2
  278. package/docs/it/intlayer_with_react_router_v7_fs_routes.md +5 -2
  279. package/docs/it/intlayer_with_svelte_kit.md +5 -2
  280. package/docs/it/intlayer_with_tanstack.md +5 -2
  281. package/docs/it/intlayer_with_vite+preact.md +5 -2
  282. package/docs/it/intlayer_with_vite+react.md +5 -2
  283. package/docs/it/intlayer_with_vite+solid.md +5 -2
  284. package/docs/it/intlayer_with_vite+svelte.md +5 -2
  285. package/docs/it/intlayer_with_vite+vue.md +5 -2
  286. package/docs/it/readme.md +1 -1
  287. package/docs/ja/cli/index.md +6 -1
  288. package/docs/ja/cli/init.md +84 -0
  289. package/docs/ja/cli/push.md +1 -1
  290. package/docs/ja/configuration.md +3 -3
  291. package/docs/ja/interest_of_intlayer.md +1 -1
  292. package/docs/ja/intlayer_CMS.md +5 -5
  293. package/docs/ja/intlayer_with_angular.md +5 -2
  294. package/docs/ja/intlayer_with_astro.md +5 -2
  295. package/docs/ja/intlayer_with_create_react_app.md +5 -2
  296. package/docs/ja/intlayer_with_express.md +6 -2
  297. package/docs/ja/intlayer_with_fastify.md +516 -0
  298. package/docs/ja/intlayer_with_lynx+react.md +5 -2
  299. package/docs/ja/intlayer_with_nestjs.md +5 -2
  300. package/docs/ja/intlayer_with_nextjs_14.md +5 -2
  301. package/docs/ja/intlayer_with_nextjs_15.md +5 -2
  302. package/docs/ja/intlayer_with_nextjs_16.md +4 -1
  303. package/docs/ja/intlayer_with_nextjs_page_router.md +5 -2
  304. package/docs/ja/intlayer_with_nuxt.md +1 -1
  305. package/docs/ja/intlayer_with_react_native+expo.md +5 -2
  306. package/docs/ja/intlayer_with_react_router_v7.md +5 -2
  307. package/docs/ja/intlayer_with_react_router_v7_fs_routes.md +5 -2
  308. package/docs/ja/intlayer_with_svelte_kit.md +5 -2
  309. package/docs/ja/intlayer_with_tanstack.md +5 -2
  310. package/docs/ja/intlayer_with_vite+preact.md +5 -2
  311. package/docs/ja/intlayer_with_vite+react.md +5 -2
  312. package/docs/ja/intlayer_with_vite+solid.md +5 -2
  313. package/docs/ja/intlayer_with_vite+svelte.md +5 -2
  314. package/docs/ja/intlayer_with_vite+vue.md +5 -2
  315. package/docs/ja/readme.md +1 -1
  316. package/docs/ko/cli/index.md +6 -1
  317. package/docs/ko/cli/init.md +92 -0
  318. package/docs/ko/cli/push.md +1 -1
  319. package/docs/ko/configuration.md +3 -3
  320. package/docs/ko/interest_of_intlayer.md +1 -1
  321. package/docs/ko/intlayer_CMS.md +5 -5
  322. package/docs/ko/intlayer_with_angular.md +5 -2
  323. package/docs/ko/intlayer_with_astro.md +5 -2
  324. package/docs/ko/intlayer_with_create_react_app.md +5 -2
  325. package/docs/ko/intlayer_with_express.md +6 -2
  326. package/docs/ko/intlayer_with_fastify.md +463 -0
  327. package/docs/ko/intlayer_with_lynx+react.md +5 -2
  328. package/docs/ko/intlayer_with_nestjs.md +5 -2
  329. package/docs/ko/intlayer_with_nextjs_14.md +5 -2
  330. package/docs/ko/intlayer_with_nextjs_15.md +5 -2
  331. package/docs/ko/intlayer_with_nextjs_16.md +4 -1
  332. package/docs/ko/intlayer_with_nextjs_page_router.md +5 -2
  333. package/docs/ko/intlayer_with_nuxt.md +1 -1
  334. package/docs/ko/intlayer_with_react_native+expo.md +5 -2
  335. package/docs/ko/intlayer_with_react_router_v7.md +5 -2
  336. package/docs/ko/intlayer_with_react_router_v7_fs_routes.md +5 -2
  337. package/docs/ko/intlayer_with_svelte_kit.md +5 -2
  338. package/docs/ko/intlayer_with_tanstack.md +5 -2
  339. package/docs/ko/intlayer_with_vite+preact.md +5 -2
  340. package/docs/ko/intlayer_with_vite+react.md +5 -2
  341. package/docs/ko/intlayer_with_vite+solid.md +5 -2
  342. package/docs/ko/intlayer_with_vite+svelte.md +4 -1
  343. package/docs/ko/intlayer_with_vite+vue.md +5 -2
  344. package/docs/ko/readme.md +1 -1
  345. package/docs/pl/cli/index.md +6 -1
  346. package/docs/pl/cli/init.md +92 -0
  347. package/docs/pl/cli/push.md +1 -1
  348. package/docs/pl/configuration.md +3 -3
  349. package/docs/pl/interest_of_intlayer.md +1 -1
  350. package/docs/pl/intlayer_CMS.md +5 -5
  351. package/docs/pl/intlayer_with_angular.md +5 -2
  352. package/docs/pl/intlayer_with_astro.md +6 -3
  353. package/docs/pl/intlayer_with_create_react_app.md +5 -2
  354. package/docs/pl/intlayer_with_express.md +6 -2
  355. package/docs/pl/intlayer_with_fastify.md +457 -0
  356. package/docs/pl/intlayer_with_lynx+react.md +5 -2
  357. package/docs/pl/intlayer_with_nestjs.md +5 -2
  358. package/docs/pl/intlayer_with_next-i18next.md +1 -1
  359. package/docs/pl/intlayer_with_next-intl.md +1 -1
  360. package/docs/pl/intlayer_with_nextjs_14.md +5 -2
  361. package/docs/pl/intlayer_with_nextjs_15.md +5 -2
  362. package/docs/pl/intlayer_with_nextjs_16.md +5 -2
  363. package/docs/pl/intlayer_with_nextjs_page_router.md +5 -2
  364. package/docs/pl/intlayer_with_nuxt.md +1 -1
  365. package/docs/pl/intlayer_with_react_native+expo.md +5 -2
  366. package/docs/pl/intlayer_with_react_router_v7.md +5 -2
  367. package/docs/pl/intlayer_with_react_router_v7_fs_routes.md +5 -2
  368. package/docs/pl/intlayer_with_svelte_kit.md +5 -2
  369. package/docs/pl/intlayer_with_tanstack.md +5 -2
  370. package/docs/pl/intlayer_with_vite+preact.md +5 -2
  371. package/docs/pl/intlayer_with_vite+react.md +5 -2
  372. package/docs/pl/intlayer_with_vite+solid.md +5 -2
  373. package/docs/pl/intlayer_with_vite+svelte.md +5 -2
  374. package/docs/pl/intlayer_with_vite+vue.md +5 -2
  375. package/docs/pl/readme.md +1 -1
  376. package/docs/pt/cli/index.md +6 -1
  377. package/docs/pt/cli/init.md +92 -0
  378. package/docs/pt/cli/push.md +1 -1
  379. package/docs/pt/configuration.md +3 -3
  380. package/docs/pt/interest_of_intlayer.md +1 -1
  381. package/docs/pt/intlayer_CMS.md +5 -5
  382. package/docs/pt/intlayer_with_angular.md +5 -2
  383. package/docs/pt/intlayer_with_astro.md +5 -2
  384. package/docs/pt/intlayer_with_create_react_app.md +5 -2
  385. package/docs/pt/intlayer_with_express.md +6 -2
  386. package/docs/pt/intlayer_with_fastify.md +502 -0
  387. package/docs/pt/intlayer_with_lynx+react.md +5 -2
  388. package/docs/pt/intlayer_with_nestjs.md +5 -2
  389. package/docs/pt/intlayer_with_next-i18next.md +1 -1
  390. package/docs/pt/intlayer_with_next-intl.md +1 -1
  391. package/docs/pt/intlayer_with_nextjs_14.md +1 -1
  392. package/docs/pt/intlayer_with_nextjs_15.md +5 -2
  393. package/docs/pt/intlayer_with_nextjs_16.md +5 -2
  394. package/docs/pt/intlayer_with_nextjs_page_router.md +5 -2
  395. package/docs/pt/intlayer_with_nuxt.md +1 -1
  396. package/docs/pt/intlayer_with_react_native+expo.md +5 -2
  397. package/docs/pt/intlayer_with_react_router_v7.md +5 -2
  398. package/docs/pt/intlayer_with_react_router_v7_fs_routes.md +5 -2
  399. package/docs/pt/intlayer_with_svelte_kit.md +5 -2
  400. package/docs/pt/intlayer_with_tanstack.md +5 -2
  401. package/docs/pt/intlayer_with_vite+preact.md +5 -2
  402. package/docs/pt/intlayer_with_vite+react.md +5 -2
  403. package/docs/pt/intlayer_with_vite+solid.md +5 -2
  404. package/docs/pt/intlayer_with_vite+svelte.md +5 -2
  405. package/docs/pt/intlayer_with_vite+vue.md +5 -2
  406. package/docs/pt/readme.md +1 -1
  407. package/docs/ru/cli/index.md +6 -1
  408. package/docs/ru/cli/init.md +92 -0
  409. package/docs/ru/cli/push.md +1 -1
  410. package/docs/ru/configuration.md +3 -3
  411. package/docs/ru/interest_of_intlayer.md +1 -1
  412. package/docs/ru/intlayer_CMS.md +5 -5
  413. package/docs/ru/intlayer_with_angular.md +5 -2
  414. package/docs/ru/intlayer_with_astro.md +5 -2
  415. package/docs/ru/intlayer_with_create_react_app.md +5 -2
  416. package/docs/ru/intlayer_with_express.md +6 -2
  417. package/docs/ru/intlayer_with_fastify.md +468 -0
  418. package/docs/ru/intlayer_with_lynx+react.md +5 -2
  419. package/docs/ru/intlayer_with_nestjs.md +5 -2
  420. package/docs/ru/intlayer_with_next-i18next.md +1 -1
  421. package/docs/ru/intlayer_with_next-intl.md +1 -1
  422. package/docs/ru/intlayer_with_nextjs_14.md +1 -1
  423. package/docs/ru/intlayer_with_nextjs_15.md +5 -2
  424. package/docs/ru/intlayer_with_nextjs_16.md +5 -2
  425. package/docs/ru/intlayer_with_nextjs_page_router.md +5 -2
  426. package/docs/ru/intlayer_with_nuxt.md +1 -1
  427. package/docs/ru/intlayer_with_react_native+expo.md +5 -2
  428. package/docs/ru/intlayer_with_react_router_v7.md +5 -2
  429. package/docs/ru/intlayer_with_react_router_v7_fs_routes.md +5 -2
  430. package/docs/ru/intlayer_with_svelte_kit.md +5 -2
  431. package/docs/ru/intlayer_with_tanstack.md +5 -2
  432. package/docs/ru/intlayer_with_vite+preact.md +5 -2
  433. package/docs/ru/intlayer_with_vite+react.md +5 -2
  434. package/docs/ru/intlayer_with_vite+solid.md +5 -2
  435. package/docs/ru/intlayer_with_vite+svelte.md +5 -2
  436. package/docs/ru/intlayer_with_vite+vue.md +5 -2
  437. package/docs/ru/readme.md +1 -1
  438. package/docs/tr/cli/index.md +6 -1
  439. package/docs/tr/cli/init.md +89 -0
  440. package/docs/tr/cli/push.md +1 -1
  441. package/docs/tr/configuration.md +3 -3
  442. package/docs/tr/interest_of_intlayer.md +1 -1
  443. package/docs/tr/intlayer_CMS.md +5 -5
  444. package/docs/tr/intlayer_with_angular.md +5 -2
  445. package/docs/tr/intlayer_with_astro.md +5 -2
  446. package/docs/tr/intlayer_with_create_react_app.md +5 -2
  447. package/docs/tr/intlayer_with_express.md +6 -2
  448. package/docs/tr/intlayer_with_fastify.md +471 -0
  449. package/docs/tr/intlayer_with_lynx+react.md +5 -2
  450. package/docs/tr/intlayer_with_nestjs.md +5 -2
  451. package/docs/tr/intlayer_with_next-i18next.md +1 -1
  452. package/docs/tr/intlayer_with_next-intl.md +1 -1
  453. package/docs/tr/intlayer_with_nextjs_14.md +5 -2
  454. package/docs/tr/intlayer_with_nextjs_15.md +5 -2
  455. package/docs/tr/intlayer_with_nextjs_16.md +5 -2
  456. package/docs/tr/intlayer_with_nextjs_page_router.md +5 -2
  457. package/docs/tr/intlayer_with_nuxt.md +1 -1
  458. package/docs/tr/intlayer_with_react_native+expo.md +5 -2
  459. package/docs/tr/intlayer_with_react_router_v7.md +5 -2
  460. package/docs/tr/intlayer_with_react_router_v7_fs_routes.md +5 -2
  461. package/docs/tr/intlayer_with_svelte_kit.md +5 -2
  462. package/docs/tr/intlayer_with_tanstack.md +5 -2
  463. package/docs/tr/intlayer_with_vite+preact.md +5 -2
  464. package/docs/tr/intlayer_with_vite+react.md +5 -2
  465. package/docs/tr/intlayer_with_vite+solid.md +5 -2
  466. package/docs/tr/intlayer_with_vite+svelte.md +5 -2
  467. package/docs/tr/intlayer_with_vite+vue.md +5 -2
  468. package/docs/tr/readme.md +1 -1
  469. package/docs/vi/cli/index.md +6 -1
  470. package/docs/vi/cli/init.md +84 -0
  471. package/docs/vi/cli/push.md +1 -1
  472. package/docs/vi/configuration.md +3 -3
  473. package/docs/vi/interest_of_intlayer.md +1 -1
  474. package/docs/vi/intlayer_CMS.md +5 -5
  475. package/docs/vi/intlayer_with_angular.md +5 -2
  476. package/docs/vi/intlayer_with_astro.md +5 -2
  477. package/docs/vi/intlayer_with_create_react_app.md +5 -2
  478. package/docs/vi/intlayer_with_express.md +6 -2
  479. package/docs/vi/intlayer_with_fastify.md +490 -0
  480. package/docs/vi/intlayer_with_lynx+react.md +5 -2
  481. package/docs/vi/intlayer_with_nestjs.md +5 -2
  482. package/docs/vi/intlayer_with_next-i18next.md +1 -1
  483. package/docs/vi/intlayer_with_next-intl.md +1 -1
  484. package/docs/vi/intlayer_with_nextjs_14.md +5 -2
  485. package/docs/vi/intlayer_with_nextjs_15.md +5 -2
  486. package/docs/vi/intlayer_with_nextjs_16.md +5 -2
  487. package/docs/vi/intlayer_with_nextjs_page_router.md +5 -2
  488. package/docs/vi/intlayer_with_nuxt.md +1 -1
  489. package/docs/vi/intlayer_with_react_native+expo.md +5 -2
  490. package/docs/vi/intlayer_with_react_router_v7.md +5 -2
  491. package/docs/vi/intlayer_with_react_router_v7_fs_routes.md +5 -2
  492. package/docs/vi/intlayer_with_svelte_kit.md +5 -2
  493. package/docs/vi/intlayer_with_tanstack.md +5 -2
  494. package/docs/vi/intlayer_with_vite+preact.md +5 -2
  495. package/docs/vi/intlayer_with_vite+react.md +5 -2
  496. package/docs/vi/intlayer_with_vite+solid.md +5 -2
  497. package/docs/vi/intlayer_with_vite+svelte.md +5 -2
  498. package/docs/vi/intlayer_with_vite+vue.md +5 -2
  499. package/docs/vi/readme.md +1 -1
  500. package/docs/zh/cli/index.md +6 -1
  501. package/docs/zh/cli/init.md +84 -0
  502. package/docs/zh/cli/push.md +1 -1
  503. package/docs/zh/configuration.md +3 -3
  504. package/docs/zh/interest_of_intlayer.md +1 -1
  505. package/docs/zh/intlayer_CMS.md +5 -5
  506. package/docs/zh/intlayer_with_angular.md +5 -2
  507. package/docs/zh/intlayer_with_astro.md +5 -2
  508. package/docs/zh/intlayer_with_create_react_app.md +5 -2
  509. package/docs/zh/intlayer_with_express.md +6 -2
  510. package/docs/zh/intlayer_with_fastify.md +451 -0
  511. package/docs/zh/intlayer_with_lynx+react.md +5 -2
  512. package/docs/zh/intlayer_with_nestjs.md +5 -2
  513. package/docs/zh/intlayer_with_nextjs_14.md +5 -2
  514. package/docs/zh/intlayer_with_nextjs_15.md +5 -2
  515. package/docs/zh/intlayer_with_nextjs_16.md +4 -1
  516. package/docs/zh/intlayer_with_nextjs_page_router.md +5 -2
  517. package/docs/zh/intlayer_with_react_native+expo.md +5 -2
  518. package/docs/zh/intlayer_with_react_router_v7.md +5 -2
  519. package/docs/zh/intlayer_with_react_router_v7_fs_routes.md +5 -2
  520. package/docs/zh/intlayer_with_svelte_kit.md +4 -1
  521. package/docs/zh/intlayer_with_tanstack.md +5 -2
  522. package/docs/zh/intlayer_with_vite+preact.md +5 -2
  523. package/docs/zh/intlayer_with_vite+react.md +4 -1
  524. package/docs/zh/intlayer_with_vite+solid.md +5 -2
  525. package/docs/zh/intlayer_with_vite+svelte.md +4 -1
  526. package/docs/zh/intlayer_with_vite+vue.md +5 -2
  527. package/docs/zh/readme.md +1 -1
  528. package/package.json +6 -6
  529. package/src/generated/docs.entry.ts +38 -0
@@ -0,0 +1,490 @@
1
+ ---
2
+ createdAt: 2025-12-30
3
+ updatedAt: 2025-12-30
4
+ title: Cách dịch backend Fastify của bạn – Hướng dẫn i18n 2026
5
+ description: Tìm hiểu cách làm cho backend Fastify của bạn hỗ trợ đa ngôn ngữ. Thực hiện theo tài liệu để internationalize (i18n) và dịch nội dung.
6
+ keywords:
7
+ - Quốc tế hóa (i18n)
8
+ - Tài liệu
9
+ - Intlayer
10
+ - Fastify
11
+ - JavaScript
12
+ - Backend
13
+ slugs:
14
+ - doc
15
+ - environment
16
+ - fastify
17
+ applicationTemplate: https://github.com/aymericzip/intlayer-fastify-template
18
+ history:
19
+ - version: 7.6.0
20
+ date: 2025-12-31
21
+ changes: Thêm lệnh init
22
+ - version: 7.6.0
23
+ date: 2025-12-31
24
+ changes: Khởi tạo lịch sử
25
+ ---
26
+
27
+ # Dịch backend Fastify của bạn bằng Intlayer | Quốc tế hóa (i18n)
28
+
29
+ `fastify-intlayer` là một plugin quốc tế hóa (i18n) mạnh mẽ cho các ứng dụng Fastify, được thiết kế để làm cho dịch vụ backend của bạn có thể truy cập trên toàn cầu bằng cách cung cấp phản hồi được địa phương hóa dựa trên sở thích của client.
30
+
31
+ ### Các trường hợp sử dụng thực tế
32
+
33
+ - **Hiển thị lỗi Backend bằng ngôn ngữ của người dùng**: Khi xảy ra lỗi, hiển thị thông điệp bằng ngôn ngữ mẹ đẻ của người dùng sẽ cải thiện khả năng hiểu và giảm sự bực bội. Điều này đặc biệt hữu ích cho các thông báo lỗi động có thể được hiển thị trong các thành phần front-end như toast hoặc modal.
34
+
35
+ `fastify-intlayer` là một plugin quốc tế hóa (i18n) mạnh mẽ cho các ứng dụng Fastify, được thiết kế để giúp các dịch vụ backend của bạn có thể truy cập toàn cầu bằng cách cung cấp các phản hồi địa phương hóa dựa trên sở thích của khách hàng.
36
+
37
+ ### Trường hợp sử dụng thực tế
38
+
39
+ - **Hiển thị lỗi backend bằng ngôn ngữ của người dùng**: Khi xảy ra lỗi, hiển thị thông điệp bằng ngôn ngữ mẹ đẻ của người dùng giúp họ hiểu tốt hơn và giảm bực bội. Điều này đặc biệt hữu ích cho các thông báo lỗi động có thể được hiển thị trong các thành phần front-end như toasts hoặc modals.
40
+ - **Truy xuất nội dung đa ngôn ngữ**: Đối với các ứng dụng lấy nội dung từ cơ sở dữ liệu, quốc tế hóa đảm bảo rằng bạn có thể phục vụ nội dung này bằng nhiều ngôn ngữ. Điều này rất quan trọng cho các nền tảng như trang thương mại điện tử (e-commerce) hoặc hệ thống quản lý nội dung (CMS) cần hiển thị mô tả sản phẩm, bài viết và các nội dung khác theo ngôn ngữ mà người dùng ưu tiên.
41
+ - **Gửi email đa ngôn ngữ**: Dù là email giao dịch, chiến dịch marketing hay thông báo, gửi email bằng ngôn ngữ của người nhận có thể tăng đáng kể mức độ tương tác và hiệu quả.
42
+ - **Thông báo đẩy đa ngôn ngữ**: Đối với ứng dụng di động, gửi thông báo đẩy bằng ngôn ngữ ưa thích của người dùng có thể tăng tương tác và giữ chân người dùng. Sự chăm chút cá nhân này khiến thông báo trở nên phù hợp và dễ hành động hơn.
43
+ - **Các hình thức liên lạc khác**: Bất kỳ hình thức liên lạc nào từ backend, như tin nhắn SMS, cảnh báo hệ thống hoặc cập nhật giao diện người dùng, đều hưởng lợi khi được gửi bằng ngôn ngữ của người dùng, đảm bảo sự rõ ràng và nâng cao trải nghiệm tổng thể.
44
+
45
+ Bằng cách quốc tế hóa backend, ứng dụng của bạn không chỉ tôn trọng khác biệt văn hóa mà còn phù hợp hơn với nhu cầu thị trường toàn cầu, trở thành bước then chốt để mở rộng dịch vụ ra toàn thế giới.
46
+
47
+ ## Bắt đầu
48
+
49
+ ### Cài đặt
50
+
51
+ Để bắt đầu sử dụng `fastify-intlayer`, cài gói bằng npm:
52
+
53
+ ```bash packageManager="npm"
54
+ npm install intlayer fastify-intlayer
55
+ npx intlayer init
56
+
57
+ ```
58
+
59
+ ```bash packageManager="pnpm"
60
+ pnpm add intlayer fastify-intlayer
61
+ pnpm intlayer init
62
+
63
+ ```
64
+
65
+ ```bash packageManager="yarn"
66
+ yarn add intlayer fastify-intlayer
67
+ yarn intlayer init
68
+
69
+ ```
70
+
71
+ ```bash packageManager="bun"
72
+ bun add intlayer fastify-intlayer
73
+ bunx intlayer init
74
+
75
+ ```
76
+
77
+ ### Thiết lập
78
+
79
+ Cấu hình các thiết lập quốc tế hóa bằng cách tạo một tệp `intlayer.config.ts` ở thư mục gốc của dự án:
80
+
81
+ ```typescript fileName="intlayer.config.ts" codeFormat="typescript"
82
+ import { Locales, type IntlayerConfig } from "intlayer";
83
+
84
+ const config: IntlayerConfig = {
85
+ internationalization: {
86
+ locales: [
87
+ Locales.ENGLISH,
88
+ Locales.FRENCH,
89
+ Locales.SPANISH_MEXICO,
90
+ Locales.SPANISH_SPAIN,
91
+ ],
92
+ defaultLocale: Locales.ENGLISH,
93
+ },
94
+ };
95
+
96
+ export default config;
97
+ ```
98
+
99
+ ```javascript fileName="intlayer.config.mjs" codeFormat="esm"
100
+ import { Locales } from "intlayer";
101
+
102
+ /** @type {import('intlayer').IntlayerConfig} */
103
+ const config = {
104
+ internationalization: {
105
+ locales: [
106
+ Locales.ENGLISH,
107
+ Locales.FRENCH,
108
+ Locales.SPANISH_MEXICO,
109
+ Locales.SPANISH_SPAIN,
110
+ ],
111
+ defaultLocale: Locales.ENGLISH,
112
+ },
113
+ };
114
+
115
+ export default config;
116
+ ```
117
+
118
+ ```javascript fileName="intlayer.config.cjs" codeFormat="commonjs"
119
+ const { Locales } = require("intlayer");
120
+
121
+ /** @type {import('intlayer').IntlayerConfig} */
122
+ const config = {
123
+ internationalization: {
124
+ locales: [
125
+ Locales.ENGLISH,
126
+ Locales.FRENCH,
127
+ Locales.SPANISH_MEXICO,
128
+ Locales.SPANISH_SPAIN,
129
+ ],
130
+ defaultLocale: Locales.ENGLISH,
131
+ },
132
+ };
133
+
134
+ module.exports = config;
135
+ ```
136
+
137
+ ### Khai báo Nội dung của bạn
138
+
139
+ Tạo và quản lý các khai báo nội dung của bạn để lưu trữ bản dịch:
140
+
141
+ ```typescript fileName="src/index.content.ts" contentDeclarationFormat="typescript"
142
+ import { t, type Dictionary } from "intlayer";
143
+
144
+ const indexContent = {
145
+ key: "index",
146
+ content: {
147
+ exampleOfContent: t({
148
+ vi: "Ví dụ về nội dung trả về bằng tiếng Việt",
149
+ en: "Example of returned content in English",
150
+ fr: "Exemple de contenu renvoyé en français",
151
+ "es-ES": "Ejemplo de contenido devuelto en español (España)",
152
+ "es-MX": "Ejemplo de contenido devuelto en español (México)",
153
+ }),
154
+ },
155
+ } satisfies Dictionary;
156
+
157
+ export default indexContent;
158
+ ```
159
+
160
+ ```javascript fileName="src/index.content.mjs" contentDeclarationFormat="esm"
161
+ import { t } from "intlayer";
162
+
163
+ /** Danh sách từ điển. @type {import('intlayer').Dictionary} */
164
+ const indexContent = {
165
+ key: "index",
166
+ content: {
167
+ exampleOfContent: t({
168
+ vi: "Ví dụ về nội dung trả về bằng tiếng Anh",
169
+ en: "Example of returned content in English",
170
+ fr: "Exemple de contenu renvoyé en français",
171
+ "es-ES": "Ejemplo de contenido devuelto en español (España)",
172
+ "es-MX": "Ejemplo de contenido devuelto en español (México)",
173
+ }),
174
+ },
175
+ };
176
+
177
+ export default indexContent;
178
+ ```
179
+
180
+ ```javascript fileName="src/index.content.cjs" contentDeclarationFormat="commonjs"
181
+ const { t } = require("intlayer");
182
+
183
+ /** Danh sách từ điển. @type {import('intlayer').Dictionary} */
184
+ const indexContent = {
185
+ key: "index",
186
+ content: {
187
+ exampleOfContent: t({
188
+ vi: "Ví dụ về nội dung trả về bằng tiếng Anh",
189
+ en: "Example of returned content in English",
190
+ fr: "Exemple de contenu renvoyé en français",
191
+ "es-ES": "Ejemplo de contenido devuelto en español (España)",
192
+ "es-MX": "Ejemplo de contenido devuelto en español (México)",
193
+ }),
194
+ },
195
+ };
196
+
197
+ module.exports = indexContent;
198
+ vi: "Ví dụ về nội dung được trả về bằng tiếng Việt",
199
+ en: "Example of returned content in English",
200
+ fr: "Exemple de contenu renvoyé en français",
201
+ "es-ES": "Ejemplo de contenido devuelto en español (España)",
202
+ "es-MX": "Ejemplo de contenido devuelto en español (México)",
203
+ }),
204
+ },
205
+ };
206
+
207
+ module.exports = indexContent;
208
+ ```
209
+
210
+ ```json fileName="src/index.content.json" contentDeclarationFormat="json"
211
+ {
212
+ "$schema": "https://intlayer.org/schema.json",
213
+ "key": "index",
214
+ "content": {
215
+ "exampleOfContent": {
216
+ "nodeType": "translation",
217
+ "translation": {
218
+ "vi": "Ví dụ về nội dung được trả về bằng tiếng Việt",
219
+ "en": "Example of returned content in English",
220
+ "fr": "Exemple de contenu renvoyé en français",
221
+ "es-ES": "Ejemplo de contenido devuelto en español (España)",
222
+ "es-MX": "Ejemplo de contenido devuelto en español (México)"
223
+ }
224
+ }
225
+ }
226
+ }
227
+ ```
228
+
229
+ > Các khai báo nội dung của bạn có thể được định nghĩa ở bất kỳ đâu trong ứng dụng miễn là chúng được đưa vào thư mục `contentDir` (mặc định là `./src`). Và khớp với phần mở rộng tệp khai báo nội dung (mặc định là `.content.{json,ts,tsx,js,jsx,mjs,mjx,cjs,cjx}`).
230
+
231
+ > Để biết thêm chi tiết, tham khảo [tài liệu khai báo nội dung](https://github.com/aymericzip/intlayer/blob/main/docs/docs/vi/dictionary/content_file.md).
232
+
233
+ ### Thiết lập Ứng dụng Fastify
234
+
235
+ Thiết lập ứng dụng Fastify của bạn để sử dụng `fastify-intlayer`:
236
+
237
+ ```typescript fileName="src/index.ts" codeFormat="typescript"
238
+ import Fastify from "fastify";
239
+ import { intlayer, t, getDictionary, getIntlayer } from "fastify-intlayer";
240
+ import dictionaryExample from "./index.content";
241
+
242
+ const fastify = Fastify({ logger: true });
243
+
244
+ // Tải plugin quốc tế hóa
245
+ await fastify.register(intlayer);
246
+
247
+ // Định tuyến
248
+ fastify.get("/t_example", async (_req, reply) => {
249
+ return t({
250
+ vi: "Ví dụ nội dung trả về bằng tiếng Việt",
251
+ en: "Example of returned content in English",
252
+ fr: "Exemple de contenu renvoyé en français",
253
+ "es-ES": "Ejemplo de contenido devuelto en español (España)",
254
+ "es-MX": "Ejemplo de contenido devuelto en español (México)",
255
+ });
256
+ });
257
+
258
+ fastify.get("/getIntlayer_example", async (_req, reply) => {
259
+ return getIntlayer("index").exampleOfContent;
260
+ });
261
+
262
+ fastify.get("/getDictionary_example", async (_req, reply) => {
263
+ return getDictionary(dictionaryExample).exampleOfContent;
264
+ });
265
+
266
+ // Khởi động server
267
+ const start = async () => {
268
+ try {
269
+ await fastify.listen({ port: 3000 });
270
+ } catch (err) {
271
+ fastify.log.error(err);
272
+ process.exit(1);
273
+ }
274
+ };
275
+
276
+ start();
277
+ ```
278
+
279
+ ```javascript fileName="src/index.mjs" codeFormat="esm"
280
+ import Fastify from "fastify";
281
+ import { intlayer, t, getDictionary, getIntlayer } from "fastify-intlayer";
282
+ import dictionaryExample from "./index.content";
283
+
284
+ const fastify = Fastify({ logger: true });
285
+
286
+ // Đăng ký plugin quốc tế hóa
287
+ await fastify.register(intlayer);
288
+
289
+ // Các route
290
+ fastify.get("/t_example", async (_req, reply) => {
291
+ return t({
292
+ vi: "Ví dụ nội dung trả về bằng tiếng Việt",
293
+ en: "Example of returned content in English",
294
+ fr: "Exemple de contenu renvoyé en français",
295
+ "es-ES": "Ejemplo de contenido devuelto en español (España)",
296
+ "es-MX": "Ejemplo de contenido devuelto en español (México)",
297
+ });
298
+ });
299
+
300
+ fastify.get("/getIntlayer_example", async (_req, reply) => {
301
+ return getIntlayer("index").exampleOfContent;
302
+ });
303
+
304
+ fastify.get("/getDictionary_example", async (_req, reply) => {
305
+ return getDictionary(dictionaryExample).exampleOfContent;
306
+ });
307
+
308
+ // Bắt đầu server
309
+ const start = async () => {
310
+ try {
311
+ await fastify.listen({ port: 3000 });
312
+ } catch (err) {
313
+ fastify.log.error(err);
314
+ process.exit(1);
315
+ }
316
+ };
317
+
318
+ start();
319
+ ```
320
+
321
+ ```javascript fileName="src/index.cjs" codeFormat="commonjs"
322
+ const Fastify = require("fastify");
323
+ const { intlayer, t, getDictionary, getIntlayer } = require("fastify-intlayer");
324
+ const dictionaryExample = require("./index.content");
325
+
326
+ const fastify = Fastify({ logger: true });
327
+
328
+ // Wrapper khởi động server để hỗ trợ async/await
329
+ const start = async () => {
330
+ try {
331
+ // Đăng ký plugin quốc tế hóa
332
+ await fastify.register(intlayer);
333
+
334
+ // Các routes
335
+ fastify.get("/t_example", async (_req, reply) => {
336
+ return t({
337
+ vi: "Ví dụ về nội dung trả về bằng tiếng Việt",
338
+ en: "Example of returned content in English",
339
+ fr: "Exemple de contenu renvoyé en français",
340
+ "es-ES": "Ejemplo de contenido devuelto en español (España)",
341
+ "es-MX": "Ejemplo de contenido devuelto en español (México)",
342
+ });
343
+ });
344
+
345
+ fastify.get("/getIntlayer_example", async (_req, reply) => {
346
+ return getIntlayer("index").exampleOfContent;
347
+ });
348
+
349
+ fastify.get("/getDictionary_example", async (_req, reply) => {
350
+ return getDictionary(dictionaryExample).exampleOfContent;
351
+ });
352
+
353
+ await fastify.listen({ port: 3000 });
354
+ } catch (err) {
355
+ fastify.log.error(err);
356
+ process.exit(1);
357
+ }
358
+ };
359
+
360
+ start();
361
+ fastify.get("/t_example", async (_req, reply) => {
362
+ return t({
363
+ vi: "Ví dụ về nội dung trả về bằng tiếng Việt",
364
+ en: "Example of returned content in English",
365
+ fr: "Exemple de contenu renvoyé en français",
366
+ "es-ES": "Ejemplo de contenido devuelto en español (España)",
367
+ "es-MX": "Ejemplo de contenido devuelto en español (México)",
368
+ });
369
+ });
370
+
371
+ fastify.get("/getIntlayer_example", async (_req, reply) => {
372
+ return getIntlayer("index").exampleOfContent;
373
+ });
374
+
375
+ fastify.get("/getDictionary_example", async (_req, reply) => {
376
+ return getDictionary(dictionaryExample).exampleOfContent;
377
+ });
378
+
379
+ await fastify.listen({ port: 3000 });
380
+ } catch (err) {
381
+ fastify.log.error(err);
382
+ process.exit(1);
383
+ }
384
+ };
385
+
386
+ start();
387
+ ```
388
+
389
+ ### Tương thích
390
+
391
+ `fastify-intlayer` tương thích hoàn toàn với:
392
+
393
+ - [`react-intlayer`](<https://www.google.com/search?q=%5Bhttps://github.com/aymericzip/intlayer/blob/main/docs/docs/vi/packages/react-intlayer/index.md%5D(https://github.com/aymericzip/intlayer/blob/main/docs/docs/vi/packages/react-intlayer/index.md)>) cho các ứng dụng React
394
+ - [`next-intlayer`](<https://www.google.com/search?q=%5Bhttps://github.com/aymericzip/intlayer/blob/main/docs/docs/vi/packages/next-intlayer/index.md%5D(https://github.com/aymericzip/intlayer/blob/main/docs/docs/vi/packages/next-intlayer/index.md)>) cho các ứng dụng Next.js
395
+
396
+ - [`react-intlayer`](<https://www.google.com/search?q=%5Bhttps://github.com/aymericzip/intlayer/blob/main/docs/docs/vi/packages/react-intlayer/index.md%5D(https://github.com/aymericzip/intlayer/blob/main/docs/docs/vi/packages/react-intlayer/index.md)>) cho ứng dụng React
397
+ - [`next-intlayer`](<https://www.google.com/search?q=%5Bhttps://github.com/aymericzip/intlayer/blob/main/docs/docs/vi/packages/next-intlayer/index.md%5D(https://github.com/aymericzip/intlayer/blob/main/docs/docs/vi/packages/next-intlayer/index.md)>) cho ứng dụng Next.js
398
+ - [`vite-intlayer`](<https://www.google.com/search?q=%5Bhttps://github.com/aymericzip/intlayer/blob/main/docs/docs/vi/packages/vite-intlayer/index.md%5D(https://github.com/aymericzip/intlayer/blob/main/docs/docs/vi/packages/vite-intlayer/index.md)>) cho ứng dụng Vite
399
+
400
+ Nó cũng hoạt động mượt mà với bất kỳ giải pháp quốc tế hóa nào trên nhiều môi trường khác nhau, bao gồm trình duyệt và các yêu cầu API. Bạn có thể tùy chỉnh middleware để phát hiện locale thông qua headers hoặc cookies:
401
+
402
+ ```typescript fileName="intlayer.config.ts" codeFormat="typescript"
403
+ import { Locales, type IntlayerConfig } from "intlayer";
404
+
405
+ const config: IntlayerConfig = {
406
+ // ... Các tùy chọn cấu hình khác
407
+ middleware: {
408
+ headerName: "my-locale-header",
409
+ cookieName: "my-locale-cookie",
410
+ },
411
+ };
412
+
413
+ export default config;
414
+ ```
415
+
416
+ ```javascript fileName="intlayer.config.mjs" codeFormat="esm"
417
+ import { Locales } from "intlayer";
418
+
419
+ /** @type {import('intlayer').IntlayerConfig} */
420
+ const config = {
421
+ // ... Các tuỳ chọn cấu hình khác
422
+ middleware: {
423
+ headerName: "my-locale-header",
424
+ cookieName: "my-locale-cookie",
425
+ },
426
+ };
427
+
428
+ export default config;
429
+ ```
430
+
431
+ ```javascript fileName="intlayer.config.cjs" codeFormat="commonjs"
432
+ const { Locales } = require("intlayer");
433
+
434
+ /** @type {import('intlayer').IntlayerConfig} */
435
+ const config = {
436
+ // ... Các tuỳ chọn cấu hình khác
437
+ middleware: {
438
+ headerName: "my-locale-header",
439
+ cookieName: "my-locale-cookie",
440
+ },
441
+ };
442
+
443
+ module.exports = config;
444
+ ```
445
+
446
+ Mặc định, `fastify-intlayer` sẽ sử dụng header `Accept-Language` để xác định ngôn ngữ ưu tiên của client.
447
+
448
+ > Để biết thêm thông tin về cấu hình và các chủ đề nâng cao, hãy xem [tài liệu của chúng tôi](https://github.com/aymericzip/intlayer/blob/main/docs/docs/vi/configuration.md).
449
+
450
+ ### Cấu hình TypeScript
451
+
452
+ `fastify-intlayer` tận dụng khả năng mạnh mẽ của TypeScript để cải thiện quá trình quốc tế hóa. Hệ thống kiểu tĩnh của TypeScript đảm bảo mọi translation key đều được kiểm kê, giảm nguy cơ thiếu bản dịch và cải thiện khả năng bảo trì.
453
+
454
+ Đảm bảo các kiểu được tự động sinh (mặc định tại ./types/intlayer.d.ts) được bao gồm trong file tsconfig.json của bạn.
455
+
456
+ ```json5 fileName="tsconfig.json"
457
+ {
458
+ // ... Cấu hình TypeScript hiện có của bạn
459
+ "include": [
460
+ // ... Cấu hình TypeScript hiện có của bạn
461
+ ".intlayer/**/*.ts", // Bao gồm các kiểu được tự động sinh
462
+ ],
463
+ }
464
+ ```
465
+
466
+ ### Tiện ích mở rộng VS Code
467
+
468
+ Để cải thiện trải nghiệm phát triển với Intlayer, bạn có thể cài đặt **Tiện ích mở rộng Intlayer cho VS Code** chính thức.
469
+
470
+ [Cài đặt từ VS Code Marketplace](https://marketplace.visualstudio.com/items?itemName=intlayer.intlayer-vs-code-extension)
471
+
472
+ Tiện ích mở rộng này cung cấp:
473
+
474
+ - **Tự động hoàn thành** cho các khóa dịch.
475
+ - **Phát hiện lỗi thời gian thực** cho các bản dịch bị thiếu.
476
+ - **Xem trước trực tiếp** nội dung đã dịch ngay trong trình soạn thảo.
477
+ - **Hành động nhanh** để dễ dàng tạo và cập nhật bản dịch.
478
+
479
+ Để biết thêm chi tiết về cách sử dụng tiện ích mở rộng, tham khảo [tài liệu Tiện ích mở rộng Intlayer cho VS Code](https://intlayer.org/doc/vs-code-extension).
480
+
481
+ ### Cấu hình Git
482
+
483
+ Nên bỏ qua các tệp do Intlayer tạo ra. Điều này giúp bạn tránh commit chúng vào kho Git của mình.
484
+
485
+ Để làm điều này, bạn có thể thêm các hướng dẫn sau vào tệp `.gitignore` của mình:
486
+
487
+ ```plaintext fileName=".gitignore"
488
+ # Bỏ qua các tệp được Intlayer tạo ra
489
+ .intlayer
490
+ ```
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  createdAt: 2025-03-09
3
- updatedAt: 2025-06-29
4
- title: Cách dịch ứng dụng di động Lynx và React của bạn – Hướng dẫn i18n 2025
3
+ updatedAt: 2025-12-30
4
+ title: Cách dịch ứng dụng di động Lynx và React của bạn – Hướng dẫn i18n 2026
5
5
  description: Khám phá cách làm cho ứng dụng di động Lynx và React của bạn đa ngôn ngữ. Theo dõi tài liệu để quốc tế hóa (i18n) và dịch nó.
6
6
  keywords:
7
7
  - Quốc tế hóa
@@ -17,6 +17,9 @@ slugs:
17
17
  - lynx-and-react
18
18
  applicationTemplate: https://github.com/aymericzip/intlayer-lynx-template
19
19
  history:
20
+ - version: 7.5.9
21
+ date: 2025-12-30
22
+ changes: Thêm lệnh init
20
23
  - version: 5.5.10
21
24
  date: 2025-06-29
22
25
  changes: Khởi tạo lịch sử
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  createdAt: 2025-09-09
3
- updatedAt: 2025-09-09
4
- title: Cách dịch backend Nest của bạn – Hướng dẫn i18n 2025
3
+ updatedAt: 2025-12-30
4
+ title: Cách dịch backend Nest của bạn – Hướng dẫn i18n 2026
5
5
  description: Khám phá cách làm cho backend NestJS của bạn đa ngôn ngữ. Theo dõi tài liệu để quốc tế hóa (i18n) và dịch nó.
6
6
  keywords:
7
7
  - Quốc tế hóa
@@ -17,6 +17,9 @@ slugs:
17
17
  applicationTemplate: https://github.com/AydinTheFirst/nestjs-intlayer
18
18
  author: AydinTheFirst
19
19
  history:
20
+ - version: 7.5.9
21
+ date: 2025-12-30
22
+ changes: Thêm lệnh init
20
23
  - version: 5.8.0
21
24
  date: 2025-09-09
22
25
  changes: Tài liệu ban đầu
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  createdAt: 2025-10-05
3
3
  updatedAt: 2025-10-05
4
- title: Cách dịch ứng dụng Next.js 15 của bạn sử dụng next-i18next – hướng dẫn i18n 2025
4
+ title: Cách dịch ứng dụng Next.js 15 của bạn sử dụng next-i18next – hướng dẫn i18n 2026
5
5
  description: Hướng dẫn thực tiễn, sẵn sàng cho sản xuất để quốc tế hóa ứng dụng Next.js 15 App Router với i18next/next-i18next và nâng cao với Intlayer.
6
6
  keywords:
7
7
  - Quốc tế hóa
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  createdAt: 2025-10-05
3
3
  updatedAt: 2025-10-05
4
- title: Cách dịch Next.js 15 của bạn sử dụng next-intl – hướng dẫn i18n 2025
4
+ title: Cách dịch Next.js 15 của bạn sử dụng next-intl – hướng dẫn i18n 2026
5
5
  description: Khám phá cách làm cho website Next.js 15 App Router của bạn đa ngôn ngữ. Theo dõi tài liệu để quốc tế hóa (i18n) và dịch nó.
6
6
  keywords:
7
7
  - Quốc tế hóa
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  createdAt: 2024-12-06
3
- updatedAt: 2025-09-22
4
- title: Cách dịch trang web Next.js 14 và App Router của bạn – hướng dẫn i18n 2025
3
+ updatedAt: 2025-12-30
4
+ title: Cách dịch trang web Next.js 14 và App Router của bạn – hướng dẫn i18n 2026
5
5
  description: Khám phá cách làm cho trang web Next.js 14 App Router của bạn đa ngôn ngữ. Theo dõi tài liệu để quốc tế hóa (i18n) và dịch nó.
6
6
  keywords:
7
7
  - Quốc tế hóa
@@ -17,6 +17,9 @@ slugs:
17
17
  - 14
18
18
  applicationTemplate: https://github.com/aymericzip/intlayer-next-14-template
19
19
  history:
20
+ - version: 7.5.9
21
+ date: 2025-12-30
22
+ changes: Thêm lệnh init
20
23
  - version: 6.2.0
21
24
  date: 2025-10-09
22
25
  changes: Thêm tài liệu cho hook `useLocale` với tùy chọn `onLocaleChange`
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  createdAt: 2025-10-25
3
- updatedAt: 2025-11-01
4
- title: Cách dịch ứng dụng Next.js 15 của bạn – Hướng dẫn i18n 2025
3
+ updatedAt: 2025-12-30
4
+ title: Cách dịch ứng dụng Next.js 15 của bạn – Hướng dẫn i18n 2026
5
5
  description: Khám phá cách làm cho trang web Next.js 15 của bạn đa ngôn ngữ. Theo dõi tài liệu để quốc tế hóa (i18n) và dịch nó.
6
6
  keywords:
7
7
  - Quốc tế hóa
@@ -18,6 +18,9 @@ slugs:
18
18
  applicationTemplate: https://github.com/aymericzip/intlayer-next-15-template
19
19
  youtubeVideo: https://www.youtube.com/watch?v=e_PPG7PTqGU
20
20
  history:
21
+ - version: 7.5.9
22
+ date: 2025-12-30
23
+ changes: Thêm lệnh init
21
24
  - version: 7.0.6
22
25
  date: 2025-11-01
23
26
  changes: Thêm đề cập đến `x-default` trong đối tượng `alternates`
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  createdAt: 2024-12-06
3
- updatedAt: 2025-10-26
4
- title: Cách dịch ứng dụng Next.js 16 của bạn – Hướng dẫn i18n 2025
3
+ updatedAt: 2025-12-30
4
+ title: Cách dịch ứng dụng Next.js 16 của bạn – Hướng dẫn i18n 2026
5
5
  description: Khám phá cách làm cho trang web Next.js 16 của bạn đa ngôn ngữ. Theo dõi tài liệu để quốc tế hóa (i18n) và dịch nó.
6
6
  keywords:
7
7
  - Quốc tế hóa
@@ -17,6 +17,9 @@ slugs:
17
17
  applicationTemplate: https://github.com/aymericzip/intlayer-next-16-template
18
18
  youtubeVideo: https://www.youtube.com/watch?v=e_PPG7PTqGU
19
19
  history:
20
+ - version: 7.5.9
21
+ date: 2025-12-30
22
+ changes: Thêm lệnh init
20
23
  - version: 7.0.0
21
24
  date: 2025-06-29
22
25
  changes: Khởi tạo lịch sử
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  createdAt: 2024-12-07
3
- updatedAt: 2025-06-29
4
- title: Cách dịch ứng dụng Next.js và Page Router của bạn – Hướng dẫn i18n 2025
3
+ updatedAt: 2025-12-30
4
+ title: Cách dịch ứng dụng Next.js và Page Router của bạn – Hướng dẫn i18n 2026
5
5
  description: Khám phá cách làm cho trang web Next.js sử dụng Page Router của bạn đa ngôn ngữ. Theo dõi tài liệu để quốc tế hóa (i18n) và dịch nó.
6
6
  keywords:
7
7
  - Quốc tế hóa
@@ -17,6 +17,9 @@ slugs:
17
17
  - nextjs
18
18
  - next-with-page-router
19
19
  history:
20
+ - version: 7.5.9
21
+ date: 2025-12-30
22
+ changes: Thêm lệnh init
20
23
  - version: 5.6.0
21
24
  date: 2025-07-06
22
25
  changes: Chuyển hàm `withIntlayer()` thành hàm dựa trên promise
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  createdAt: 2025-06-18
3
3
  updatedAt: 2025-12-07
4
- title: Cách dịch ứng dụng Nuxt và Vue của bạn – Hướng dẫn i18n 2025
4
+ title: Cách dịch ứng dụng Nuxt và Vue của bạn – Hướng dẫn i18n 2026
5
5
  description: Khám phá cách làm cho trang web Nuxt và Vue của bạn đa ngôn ngữ. Theo dõi tài liệu để quốc tế hóa (i18n) và dịch nó.
6
6
  keywords:
7
7
  - Quốc tế hóa
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  createdAt: 2025-06-18
3
- updatedAt: 2025-10-02
4
- title: Cách dịch ứng dụng React Native và Expo của bạn – Hướng dẫn i18n 2025
3
+ updatedAt: 2025-12-30
4
+ title: Cách dịch ứng dụng React Native và Expo của bạn – Hướng dẫn i18n 2026
5
5
  description: Khám phá cách làm cho trang web React Native và Expo của bạn đa ngôn ngữ. Theo dõi tài liệu để quốc tế hóa (i18n) và dịch nó.
6
6
  keywords:
7
7
  - Quốc tế hóa
@@ -16,6 +16,9 @@ slugs:
16
16
  - react-native-and-expo
17
17
  applicationTemplate: https://github.com/aymericzip/intlayer-react-native-template
18
18
  history:
19
+ - version: 7.5.9
20
+ date: 2025-12-30
21
+ changes: Thêm lệnh init
19
22
  - version: 6.1.6
20
23
  date: 2025-10-02
21
24
  changes: Thêm phần debug
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  createdAt: 2025-09-04
3
- updatedAt: 2025-12-27
4
- title: Cách dịch ứng dụng React Router v7 của bạn – hướng dẫn i18n 2025
3
+ updatedAt: 2025-12-30
4
+ title: Cách dịch ứng dụng React Router v7 của bạn – hướng dẫn i18n 2026
5
5
  description: Tìm hiểu cách thêm quốc tế hóa (i18n) vào ứng dụng React Router v7 của bạn bằng Intlayer. Theo dõi hướng dẫn toàn diện này để làm cho ứng dụng của bạn đa ngôn ngữ với định tuyến nhận biết locale.
6
6
  keywords:
7
7
  - Quốc tế hóa
@@ -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.9
24
+ date: 2025-12-30
25
+ changes: Thêm lệnh init
23
26
  - version: 7.5.6
24
27
  date: 2025-12-27
25
28
  changes: Cập nhật Layout và xử lý 404