
Set up a TypeScript project with npm and wheat, choose vanilla JavaScript then TypeScript, run the dev server, and understand tsconfig.json; console lacks TypeScript errors, but VS Code shows them.
Differentiate JavaScript and TypeScript: JavaScript runs in browsers; TypeScript, built on JavaScript, adds typings and transpiles to JavaScript to catch errors at compile time and enable scalable apps.
Change the file extension from JavaScript to TypeScript and see how TypeScript immediately adds typing and autocomplete to existing code, flagging errors for non-existent functions.
Download the course PDF to access TypeScript interview questions, including interfaces and a read only helper, with code examples for offline practice and self-assessment.
Access curated source code archives linked to videos, enabling you to download a ready-to-run project and start solving each interview question.
Define basic types in TypeScript by assigning string, boolean, and number values, model objects with id and name, and arrays of objects; inspect types in VS Code to avoid errors.
Explore the difference between explicit and implicit types in TypeScript and how the compiler infers types when not written. Understand why relying on explicit types improves safety and correctness.
Learn to write a get full name function in TypeScript that takes name and surname, returns their concatenation, and uses explicit parameter and return types to avoid implicitly any.
Show how interfaces in TypeScript type objects like user, with required id and name, enable safe, reusable code and autocomplete in functions such as getName.
Define reusable types in TypeScript with the reserved type keyword, creating an id type and a users array to show readability and maintainability across string and number data.
Contrast the difference between interface and type in TypeScript, showing how interfaces define object contracts while types can describe any shape, and how extends, intersection, and implements achieve composition.
Learn union types in TypeScript, using the pipe operator to model string or number values, apply type narrowing, and compose loading, failed, and success network states.
Explore how to narrow unions in TypeScript by using a specific property for type narrowing and instance of checks to access success, failed, or loading state and related data.
Understand void in TypeScript by examining a function that returns a string versus one that returns nothing, and how void signals no return value.
Explore the difference between void and never in TypeScript, showing when a function ends with a throw, and why never indicates no reachable end while void means no return value.
Understand why any in TypeScript is dangerous, as it disables type checks and autocomplete, and learn to avoid implicit any by enabling strict no implicit any in tsconfig.
Explore the difference between any and unknown in TypeScript, showing how unknown enforces safety and when to apply type assertions to handle uncertain inputs.
Explore how TypeScript works with the DOM, using typecasting and type assertions to safely access elements and values. Learn about nullability, element narrowing, and typed events.
Explore how TypeScript adds typed properties, constructors, and access modifiers to classes, and shows interfaces, implements, static members, and class extension with user and admin examples.
TypeScript enums store related constants as a type and value, offering numeric defaults and string values for statuses like not started, in progress, and done.
Master generics in TypeScript by learning how to add an id to objects with a generic T, constrain it with extends object, and use generic interfaces and multiple type arguments.
Explain the difference between arrays and tuples in TypeScript, with square-bracket arrays, unions, and fixed-length tuples, and show why enums or interfaces improve readability.
Learn how to define optional properties in TypeScript interfaces using the question mark, handle undefined with the Elvis operator, and apply these patterns to objects and function parameters.
Learn to type dynamic keys in a user object by replacing a string-typed columns array with key of user, preventing any and ensuring only id, name, and age are valid.
Learn how TypeScript index signatures type objects with unknown keys by using an interface like [key: string]: string, enabling any string key to map to a string value.
Learn to use the Record type in TypeScript to map string keys to numbers, create numeric records like salary, and compare its readability to index signatures.
Learn to derive new types by omitting or picking properties from existing interfaces or types using TypeScript's omit and pick utilities to enable reuse without copy-pasting.
Explore how to use the read only helper in TypeScript to wrap a user type, making all properties read only and preventing writes like user.name.
Explore how the Partial helper in TypeScript marks all interface properties optional, allowing safe partial updates by merging a user with only the fields to update.
Discover how TypeScript's required helper enforces non-optional properties, compare it with partial, and see how to turn an optional user interface into required fields.
Learn how to integrate TypeScript with React, typing components and props, using interfaces, return types, and hooks to build robust, type-safe UI.
Learn how TypeScript infers data types when you omit explicit types, distinguishing implicit types from explicit ones, and understand how type inference appears in interviews.
Explore literal types in TypeScript, including string literal types, number literals like zero, and boolean literals, and use unions such as 'is in' or 'is out' to drive animate logic.
Explore tsconfig.json, the TypeScript project configuration file in the root folder, detailing include, compilerOptions such as target, module, moduleResolution, lib, and strict linting to catch errors.
Discover the core components of TypeScript, including the language itself, the TypeScript compiler, and the TypeScript language service, which enables features like autocomplete and go to declaration.
Learn to transpile TypeScript to JavaScript with the TypeScript Command Line Tool (TSC), specify source and output files, and see how types are removed in the final JavaScript.
Explore how a d.ts file provides type declarations for JavaScript libraries in TypeScript, enabling typings and seamless TypeScript support when building or consuming libraries.
Explore how dot map files, or source maps, link built JavaScript to the original TypeScript sources, allowing debugging of non-minified code in the browser.
Explore the advanced section of TypeScript, focusing on library design and low-level typings, and understand why typing inside TypeScript suits libraries but not everyday projects.
Demonstrate function overloading in TypeScript with a grid function that greets a string or an array of strings, using overload signatures and a single implementation. Explain its limitations and usage.
Understand how the extends keyword constrains types in TypeScript, acting as a type-level if or ternary within generics to yield string, never, and handle null or undefined via unions.
Explore how the TypeScript infer keyword works inside extends to unwrap and store types, and learn practical examples for extracting return types, first arguments, promise results, and array elements.
Explore building a read only helper in TypeScript by mapping every property of a generic interface or type to a read only version.
Define a generic first type that takes an array T and returns its first element type, using extends and t[0], or using length to return never for empty arrays.
Learn to build a generic type that returns the length of a tuple in TypeScript by extending an array, with concrete examples like Tesla and Space six.
Implement a generic utility type if that selects between T and F based on a boolean C; if C extends true it returns T, else F.
Learn to implement a concat type in TypeScript by merging two arrays in left-to-right order with generic types and spreads.
Practice randomly selected TypeScript interview questions and answer them; remember that failures are normal, keep going, and after interviews write down unknown questions to study for future interviews.
This course is great preparation for any TypeScript programming interviews that you may have coming up. Programming interviews need a lot amount of knowledge, but the best way to prepare for interviews is a lot of practice! In this course you will complete 44 TypeScript interview questions that come from real TypeScript interviews. There are no excersises that nobody asks here. In every question we will get a task first, then you will try to solve each problem yourself, and then I will show you different solutions to each problem step-by-step for different programmer levels. We will take a deep dive into the skills, concepts, and techniques that are required to solve each problem.
When you have completed this course you will have mastered the 44 interview questions that we will cover, but you will also have learned the concepts, skills, and techniques, that are necessary for you to excel in any other interview questions you may be asked. You will feel very confident going into any TypeScript programming interviews you will have. On top of all this, you will strengthen your TypeScript programming skills and TypeScript fundamentals in overall.
Core topics of the course:
Types & Interfaces
Generics
Working with classes
Working with DOM
Tuples
Enums
React with Typescript
Extends & Infer
Void, Any, Unknown, Never data types
Readonly, Pick, Omit, Partial, Required data type helpers