Reddit Programming
208 subscribers
1.22K photos
124K links
I will send you newest post from subreddit /r/programming
Download Telegram
How to test and replace any missing translations with i18next
https://www.reddit.com/r/programming/comments/1oi5f42/how_to_test_and_replace_any_missing_translations/

<!-- SC_OFF -->I recently found a really practical way to detect and fill missing translations when working with i18next and honestly, it saves a ton of time when you have dozens of JSON files to maintain. Step 1 — Test for missing translations You can now automatically check if you’re missing any keys in your localization files. It works with your CLI, CI/CD pipelines, or even your Jest/Vitest test suite. Example: npx intlayer test:i18next It scans your codebase, compares it to your JSON files, and outputs which keys are missing or unused. Super handy before deploying or merging a PR. Step 2 — Automatically fill missing translations You can choose your AI provider (ChatGPT, Claude, DeepSeek, or Mistral) and use your own API key to auto-fill missing entries. Only the missing strings get translated, your existing ones stay untouched. Example: npx intlayer translate:i18next --provider=chatgpt It will generate translations for missing keys in all your locales. Step 3 — Integrate in CI/CD You can plug it into your CI to make sure no new missing keys are introduced: npx intlayer test:i18next --ci If missing translations are found, it can fail the pipeline or just log warnings depending on your config. Bonus: Detect JSON changes via Git There’s even a (WIP) feature that detects which lines changed in your translation JSON using git diff, so it only re-translates what was modified. If you’re using Next.js Here’s a guide that explains how to set it up with next-i18next (based on i18next under the hood): 👉 https://intlayer.org/fr/blog/intlayer-with-next-i18next TL;DR Test missing translations automatically Auto-fill missing JSON entries using AI Integrate with CI/CDWorks with i18next <!-- SC_ON --> submitted by /u/AdmirableJackfruit59 (https://www.reddit.com/user/AdmirableJackfruit59)
[link] (https://intlayer.org/fr/blog/intlayer-with-next-i18next) [comments] (https://www.reddit.com/r/programming/comments/1oi5f42/how_to_test_and_replace_any_missing_translations/)
Faster Database Queries: Practical Techniques
https://www.reddit.com/r/programming/comments/1oi99yw/faster_database_queries_practical_techniques/

<!-- SC_OFF -->Published a new write-up on Medium, If you work on highly available & scalable systems, you might find it useful <!-- SC_ON --> submitted by /u/Trust_Me_Bro_4sure (https://www.reddit.com/user/Trust_Me_Bro_4sure)
[link] (https://kapillamba4.medium.com/faster-database-queries-practical-techniques-074ba9afdaa3) [comments] (https://www.reddit.com/r/programming/comments/1oi99yw/faster_database_queries_practical_techniques/)
Lessons from scaling live events at Patreon: modeling traffic, tuning performance, and coordinating teams
https://www.reddit.com/r/programming/comments/1oicq3e/lessons_from_scaling_live_events_at_patreon/

<!-- SC_OFF -->At Patreon, we recently scaled our platform to handle tens of thousands of fans joining live events at once. By modeling real user arrivals, tuning performance, and aligning across teams, we cut web load times by 57% and halved iOS startup requests. Here’s how we did it and what we learned about scaling real-time systems under bursty load:
https://www.patreon.com/posts/from-thundering-141679975 What are some surprising lessons you’ve learned from scaling a platform you've worked on? <!-- SC_ON --> submitted by /u/patreon-eng (https://www.reddit.com/user/patreon-eng)
[link] (https://www.patreon.com/posts/from-thundering-141679975) [comments] (https://www.reddit.com/r/programming/comments/1oicq3e/lessons_from_scaling_live_events_at_patreon/)