Please enable JavaScript.
Coggle requires JavaScript to display documents.
Typescript Fundamentals - Coggle Diagram
Typescript Fundamentals
Intro
-
TypeScript is an open source, typed syntactic superset of JavaScript
Three parts: Language, Language Server and Compiler
-
-
-
Variables and values
In TypeScript, variables are “born” with their types.
-
-
-
Objects, arrays, tuples
-
-
Array Types
-
const cars : { make: string, model: string, year: number} []
Tuples
a multi-element, ordered data structure, where position of each item has some special meaning or convention
-
Static vs dynamic
Sorting type systems as either static or dynamic has to do with whether type-checking is performed at compile time or runtime
-
-
-
-
-
Functions
Callable types
-
-
this types
you have to actually define the "this" keyword, type-wise
-
-
Nullish values
Null
null means: there is a value, and that value is nothing. While some people believe that null is not an important part of the JS language, I find that it’s useful to express the concept of a “nothing” result (kind of like an empty array, but not an array).
-
-
Generics
-
Type Parameters
Generics may change their type, depending on the type parameters you use with them
-
-
-
-