TypeScript 4.9 beta includes auto-accessors, new go-to-definition commands for editors. The new satisfies operator lets us validate that the type of an expression matches some type. Previously, TypeScript allowed us to narrow away any types that don’t explicitly list a property. But what about examples where notype listed a given property? In those cases, the language didn”t help us much.

13m read timeFrom devblogs.microsoft.com
Post cover image
Table of contents
What’s New Since the Beta?The satisfies OperatorUnlisted Property Narrowing with the in OperatorAuto-Accessors in ClassesChecks For Equality on NaNFile-Watching Now Uses File System Events"Remove Unused Imports" and "Sort Imports" Commands for EditorsGo-to-Definition on return KeywordsPerformance ImprovementsCorrectness Fixes and Breaking Changessubstitute Replaced With constraint on SubstitutionType sWhat’s Next

Sort: