The Fellowship of the String
summary
Year-long migration replaces an unobservable getI18nString API with two functions requireString and formatString that throw on failure so errors are detectable at dev, build, and runtime. Tooling uses AST-based codemods (jscodeshift/ast-explorer) to cut thousands of calls down to a few hundred, plus an eslint no-restricted-syntax rule to warn in the IDE. Changes follow a strangler/Mikado approach, add production alerts for any remaining old calls, and culminate in safely removing the legacy function.
AI-written summary · about
chapters (11)
- 0:00Intro
- 0:46The Localization Function
- 1:06GetI18N String
- 5:40Legacy Modernization
- 7:43Define your problem
- 8:39Gather our voices
- 13:53Marketing
- 15:02Refactoring
- 17:20Codemods
- 21:56Manual Changes
- 23:52Conclusion
related talks
35mLiving With Legacy Code
30mStrings are Evil: Methods to hide the use of primitive types
14mWe must talk about String
38mEdge-Free Programming
44mBuilding on clang-tidy to Move From printf-style to std::print-style Logging and Beyond
44mLet's talk about transpilers
05mReadable C++
36mCode Mending in the AI age
