perf: lazy-load locale files per language instead of bundling all

Split 574KB monolithic locales chunk into per-language lazy chunks:
- ru: 211KB (loaded on startup as fallback)
- fa: 143KB, en: 121KB, zh: 101KB (loaded on demand)

Russian users save 63% bandwidth. Other languages loaded only when
user switches via LanguageSwitcher.
This commit is contained in:
Fringg
2026-03-13 06:16:27 +03:00
parent b42d84ffe6
commit 9ae9cccbd9
2 changed files with 35 additions and 14 deletions

View File

@@ -36,7 +36,6 @@ export default defineConfig({
rollupOptions: {
output: {
manualChunks(id) {
if (id.includes('/src/locales/')) return 'locales';
if (!id.includes('node_modules')) return;
if (
id.includes('react-dom') ||