Friday, 19 May, 2023 UTC


Summary

 TypeScript 5.1, featuring easier implicit returns for undefined-returning functions and allowing unrelated types for getters and setters, is now available as a production release as of June 1.
Version 5.1 features a whole host of coding enhancements for Microsoft’s strongly typed language that builds on JavaScript. With easier implicit returns for undefined-returning functions, TypeScript 5.1 allows undefined-returning functions to have no return statement, fixing a situation in which only functions that could have absolutely no return statements were void-returning and any-returning functions. This meant that even if a developer explicitly indicated that a function returned undefined, at least one return statement was required.
To read this article in full, please click here