Description
In this course, you will :
- Advanced concepts such as type checking, iterators, and manipulating objects and arrays.
- You'll have plenty of opportunities to get your hands dirty, as well as plenty of real-world practise.
- TypeScript is a must-know language for JavaScript developers, not only today but also in the future. Don't let this opportunity pass you by.
Syllabus :
1. Introduction
- What is TypeScript?
- TypeScript Philosophy
- Why Use TypeScript?
- Using TypeScript
2. The Basics of Variables
- Declaring a Variable
- Declaring Types in Untyped Code
- Hoisting Variables
- TypeScript Scope is JavaScript Scope
- Switch Scope
- The Multiple Methods of Declaring a String
- String-Tagged Templates
- What is a Number in TypeScript?
- Booleans, Functions, and Objects
- Avoiding `any` at Any Time Possible
- Mutable and Immutable Arrays
- Undefined Versus Null
- Returning nothing with Void
- The Primitive Type never
- Unknown: A Better any
- Literal Type to Narrow Primitive Type
- Symbol and Unique Symbol
- Casting to Change Type
3. Comment
- TypeScript's Comments are like JavaScript's with One Exception
4. Enum
- Enum With and Without Values
- Accessing Enum Values
- Speeding Up Enum
- Merging and Adding Functionality to Enum
5. Generic Type
- Generic
- Generic and Classes
- Generic Constraint
- Generic with Construction Functions
- Generic Outside Class
- Generic Comparison
- Generic Inference
- Generic Default
- Generic and keyof
6. Functions
- Definition
- Named and Anonymous Functions
- Function and Inference Variables
- Generic Return Type, Optional Parameter and Default Value
- Functions in Classes
- Function Relationship with "this"
- Function and Inference Return Types
- Overload Functions to Enrich your Definition
- String Literal and Overload Function
- Types of Function Headers
7. Mapped Type
- Definition and Usages
- Immutable Data with Readonly
- Partial
- Nullable
- Pick
- Omit
- Record
- Extract
- Exclude
- ReturnType
- Custom Mapped Type
8. Objects
- Introduction to TypeScript's Many Objects
- The Curly Braces Object
- New Object
- Lowercase vs UpperCase Object
9. Index Signature
- Definitions and Usages
- String or Number Indexes
- Members of the Same Type
- Keys with Constants and Symbols
10. Variables Advanced
- Intersecting with Types, Interfaces, and Generics
- Literal Type, Narrowing, and Const
- Union with Types and Tagged Union
- Const Assertion for Literal Values
- Tuple For Type and Length Arrays
- Casting to Change Type
- keyof to Validate a Member's Name
- On How TypeScript Handles Variance
- How to Narrow a Type with the in Operator
- What is a Conditional Type?
- TypeScript Inference
- Set and Dictionary
11. Exception
- Creating an Exception
- Catching Synchronous Exceptions
- Catching Asynchronous Exceptions
- Assertion Functions
12. Alias
- Aliases with the Structural Behavior of TypeScript
- Aliases with Type
- Aliases with Generic Types and Recursivity
- The Differences between Type Aliases and Interfaces
- Branded Alias
13. Type Checking
- Comparing Variables
- Type Checking with typeof
- Type Checking with instanceof
- Type Checking and Interface with a Discriminator
- Type Checking with Intersections
- Type Checking an Interface with Custom User-Defined Type Guard
- Optional Chaining and Optional Element Access
- Nullish Coalescing
- Assertion Functions
14. Iterators
- Iterating an Object's Keys with For-In
- Iterating an Object with Standard For/While
- Iterating and the Asynchronous Loop
15. Manipulating Objects and Array
- Typing an Array
- Array with a Skipped Value
- Destructuring an Array
- Destructuring an Object
- The Spread Operator and Arrays
- The Spread Operator and Objects
- The Bang Operator
16. Sharing Code
- Namespace
- Module
- Default Module
- Lazy Loading Module
- Import Shortcuts
- Definition Files and Global Definition Files
- Definition File Locations