We’ve been seeing a lot of new solutions popping up lately, but it’s still just as hard to make a clear choice. So I took the time to compare and benchmark several internationalization solutions for Next.js and TanStack Start.
Using the same application, I tested 4 scenarios combining dynamic loading and JSON scoping with namespaces.
What I measured:
- Library size
- Page size
- Leakage of unused content per page and per locale
- Component size
- Loading time, page switching, and overall app reactivity
After 6 hours of test runs, here are the results:
The trend is surprising. The more “hyped” and trendy a solution is, the worse it performs when facing real internationalization challenges. The biggest positive surprises are not where you’d expect them.
(Consider this a v1. The interpretation of the results is somewhat influenced by my personal preferences and my experience as a solution maintainer. Feel free to share feedback or suggestions for improvement.)
1 comment
[ 5.1 ms ] story [ 18.0 ms ] threadUsing the same application, I tested 4 scenarios combining dynamic loading and JSON scoping with namespaces.
What I measured:
- Library size - Page size - Leakage of unused content per page and per locale - Component size - Loading time, page switching, and overall app reactivity
After 6 hours of test runs, here are the results:
The trend is surprising. The more “hyped” and trendy a solution is, the worse it performs when facing real internationalization challenges. The biggest positive surprises are not where you’d expect them.
Benchmark repo https://github.com/intlayer-org/benchmark-i18n
(Consider this a v1. The interpretation of the results is somewhat influenced by my personal preferences and my experience as a solution maintainer. Feel free to share feedback or suggestions for improvement.)