Course contentsShow
TypeScript
Lesson 163 of 1,7964. Type InferencePro lesson

Literals and Widening: When Inference Hurts

How inference widens literals to primitives by default and when annotations preserve the narrow literal type you need.

This lesson is for subscribers

You've completed the free preview. Subscribe to unlock every lesson in every course.