TypeScript for Beginners

Video description

Simplify your code by applying the fundamentals of TypeScript and develop the skills needed to work with Angular JS

About This Video

  • Get to grips with the basics of TypeScript and understand what it offers
  • Learn ways to create functions that take optional, default, and variable number of arguments
  • Gain insights into the key object-oriented principles used in TypeScript

In Detail

TypeScript makes the life of developers easy by simplifying code. It follows programming conventions that make the project easy to understand even for someone from the distributed team who has no prior knowledge. This makes it popular among developers who use JavaScript frameworks, AngularJS, and Vue.js. This course will show you how TypeScript provides structures such as Java and Python to make coding easy.

Starting with an introduction to TypeScript, the course highlights why you should use it. Once you've set up the development environment, you'll write your first program using Visual Studio Code to understand variables and data types in TypeScript. Next, you'll become familiar with operators and learn how to control the flow of your application with flow control statements such as If, Else, Switch, and While Loop.

As you progress, you'll develop efficient TypeScript applications using functions, interfaces, classes, and inheritance. You'll also learn how to use different access modifiers and encapsulate classes and objects. Finally, you find out how you can use typecasting to convert one data type to another and use function modules.

By the end of this course, you'll be ready to start your career as a TypeScript developer and easily learn newer versions of JavaScript such as ES 6 or 7 in the future.

Audience

Whether you are a JavaScript developer who wants to learn and master the fundamentals of TypeScript or a developer with a background in any OOP language looking to learn AngularJS, this course is for you. Basic knowledge of JavaScript is necessary to get started with this course.

Publisher resources

Download Example Code

Table of contents

  1. Chapter 1 : Introduction
    1. What and Why TypeScript
    2. TypeScript Playground
    3. Installing TypeScript
    4. Installing Visual Studio Code
  2. Chapter 2 : Variables and Data Types
    1. Introduction
    2. First Program in Visual Studio Code
    3. Using JS in a HTML
    4. Strings
    5. Boolean
    6. any Type
    7. Homogeneous Arrays
    8. Heterogeneous Arrays
    9. Using alert, confirm, and prompt
    10. Adding Comments
    11. Enum Type
    12. More about string
    13. String Functions
    14. Union Type
  3. Chapter 3 : Operators
    1. Arithmetic Operators
    2. Assigning Operators
    3. Comparing Operators
    4. Logical Operators
    5. Ternary Operators
  4. Chapter 4 : Flow Control Statements
    1. Introduction
    2. If-Else Ladder
    3. Switch Statement
    4. Break and Case Flow
    5. While Loop
    6. More Programs – 1
    7. More Programs - 2
  5. Chapter 5 : Objects and Arrays
    1. Introduction
    2. Object Literal
    3. For-In Loop
    4. Using Arrays
    5. De-Structuring Arrays
    6. De-Structuring Objects
    7. Array Functions
  6. Chapter 6 : Functions
    1. Introduction
    2. First Function
    3. Passing a Parameter
    4. Passing Multiple Parameters
    5. Using Optional Parameters
    6. Using Default Values
    7. Using Functions as Parameters
    8. Returning a Function
    9. Anonymous Functions
    10. Overloading
    11. Rest Parameter
    12. Using a Data Type with the Rest Parameter
  7. Chapter 7 : Arrow Functions
    1. Introduction
    2. First Arrow Function
    3. Passing Parameters
    4. Array of Arrow Functions
  8. Chapter 8 : Variable Prefixes
    1. let Prefix
    2. const Prefix
    3. const Functions
    4. declare Prefix
  9. Chapter 9 : Interfaces
    1. Introduction
    2. Defining an Object Interface
    3. Creating an Object
    4. Defining Optional Properties
    5. Working with Interfaces Created at Compile Time
    6. Functional Interfaces
    7. Return Types in Functional Interfaces
    8. Adding Methods to Object Interfaces
    9. Array Interfaces
    10. String Indexed Array Interfaces
    11. Extending Interfaces
  10. Chapter 10 : Classes
    1. Introduction
    2. Creating a class
    3. Adding a Constructor
    4. Adding the Function Properties
    5. Power of TypeScript
    6. Using for-in and instanceof
    7. Implementing an Interface
  11. Chapter 11 : Inheritance
    1. Introduction
    2. Extending a Class
    3. Creating Child Objects
    4. Inheriting Functionality
    5. Overriding Inheritance
  12. Chapter 12 : Access Modifiers, Encapsulation, and Static
    1. Using Public and Read-Only
    2. Encapsulation
    3. Private Properties
    4. Accessor Methods
    5. Using Static Properties
    6. More About Static
    7. Static Methods
  13. Chapter 13 : Polymorphism
    1. Introduction
    2. Polymorphism in action
  14. Chapter 14 : Static Methods
    1. String to Numeric
    2. Using the toString Method
    3. Object Casting
  15. Chapter 15 : Modules
    1. Introduction
    2. Using Function Modules
    3. Import Aliasing and Alternate Export Syntax
    4. Default Exports
    5. Class Modules
    6. Aliasing Class Modules
  16. Chapter 16 : More Types
    1. Introduction
    2. Map in action
    3. More methods on map
    4. Set
    5. Regular Expressions
    6. RegEx Program 1
    7. RegEx Program 2
    8. Date

Product information

  • Title: TypeScript for Beginners
  • Author(s): Bharath Thippireddy
  • Release date: October 2020
  • Publisher(s): Packt Publishing
  • ISBN: 9781801074476