Top
image credit: Adobe Stock

New TypeScript operator finds coding mistakes

November 2, 2022

Via: InfoWorld

Microsoft’s TypeScript 4.9, a planned upgrade to the popular, strongly typed language that builds on JavaScript, has reached the release candidate stage. The update features a satisfies operator that can catch errors.

With satisfies, developers can validate that the type of an expression matches some type, without changing the resulting type of the expression. This operator can be used to catch possible errors, such as ensuring that an object has all the keys of some type, but no more than that.

Read More on InfoWorld