Code
Migrate to strict TypeScript
Turn strict on for a module and fix what it finds.
Fill it in
Which module or package.
Which strict checks.
Fix the types rather than casting to any.
Your prompt
Turn on strictNullChecks,noImplicitAny for [your path to migrate] and fix what it finds. Do it in one module at a time and keep the build green between them. A repo-wide flip produces a thousand errors, and a thousand errors get fixed by whatever silences them fastest. Read each error as a QUESTION about the code, because that is what it is: can this actually be null here? Does this array access always hit? Most of the time the answer teaches you something, and a handful of times it is a real bug that was waiting. No escape hatches. No any, no non-null assertions, no ts-expect-error to get through. If a type genuinely cannot be expressed, say which one and why, and leave it visible. Silencing the checker reproduces exactly the state this migration exists to leave behind. Report what the migration found: the error count is uninteresting, the real bugs are the point.
Use Migrate to strict TypeScriptOpens with everything above already filled in.
Why this works
A strict migration that silences errors with `any` has moved them rather than fixed them. This types the real shapes and reports the errors that were genuine bugs.