ALT TypeScript 4.0 brings variadic tuples, labeled tuple elements, class property inference, new assignment operators, safer exception handling with 'unknown' in catch clauses, custom JSX factories, some great editor improvements, and more!
As of Typescript 3.7, you can use the “?.” syntax called “Optional Chaining” to safely navigate deep properties that might be undefined.
typescriptlang.org/docs/hand…
Use an abstract class to define methods to be implemented in classes that extend it. Typescript will throw compiler errors if they aren’t implemented correctly.
typescriptlang.org/docs/hand…
Have a hard time remembering the difference between for..in and for..of loops?
for *in* iterated *IN*dexes
for *of* iterates *o*bjects (or the elements of the iterable)
The “Parameters” built-in utility type returns a tuple type describing the arguments passed to a provided function signature.
Any terms there you don’t understand? Just ask! There’s no such thing as a bad question.
typescriptlang.org/docs/hand…
Here's my first ever #TypescriptQuiz! Name the built-in type that should replace the highlighted question marks.
(Select your answer in the poll below)
The “Omit” built-in uitility type is used to keep all properties of a given type *except* for the ones passed in the second argument.
typescriptlang.org/docs/hand…
If you're interested in TypeScript, go follow @TypescriptTutor immediately , they're just starting and I absolutely love the trend (?) of "Daily X tips"
The “Pick” built-in utility type is used for selecting a subset of keys from another type. Every key you want must be listed as the second argument.
typescriptlang.org/docs/hand…