Step 3 / Select topic TypeScript Types Easy

What this bank covers

  • Basic conditional type resolution
  • Blocking distribution with a tuple
  • infer in a conditional type
  • Inferring a function return type
  • Assigning to a resolved conditional type
  • T keeps its narrow type in the true branch
  • Nested conditional types
  • boolean distributes as true | false
  • readonly modifier in a mapped type
  • optional modifier in a mapped type
  • removing optionality with -?
  • Record as a mapped type
  • satisfying a mapped type over a key union
  • missing and excess keys for a mapped type
  • removing readonly with -readonly
  • Mapped type over a literal union
  • Cross product of placeholders
  • Numeric placeholder matching
  • A literal that fails the pattern
  • The Uppercase intrinsic
  • Capitalize inside a template
  • boolean in a placeholder
  • string is not assignable to a pattern
  • Concatenating two literals
  • Template literal type with Uppercase
  • Distributing over never
  • A union of arrays is stricter than an array of a union
  • Dropping null and undefined by distribution
  • No distribution when T is not naked
  • boolean distributes as false | true
  • Array covariance
  • Covariant up, not down
  • Return-type covariance
  • readonly arrays one-way
  • Property covariance
  • Top and bottom types
  • Tuples versus arrays
  • Parameter count rules
  • method parameter bivariance
  • Overload resolution picks the matching signature
  • satisfies keeps the expression's own type
  • satisfies does not add the target's index signature
  • satisfies on a function expression
  • satisfies is a check, not a cast
  • satisfies still runs excess property checks
  • Annotation versus satisfies for index signatures
  • Overload arity and argument types
  • satisfies checks property types and completeness
  • Overload resolution picks one signature
  • Narrowing a discriminated union by throwing
  • Indexed access on a discriminated union
  • Only shared properties are readable before narrowing
  • A union member needs its discriminant
  • The discriminant itself narrows too
  • Exhaustiveness checking with never
  • A missed case breaks the never check
  • Comparing a discriminant to a value outside the union
  • A member is assignable to its union
  • Literal inference under a string constraint
  • Argument must satisfy the constraint
  • Union constraint rejects outside members
  • keyof constraint with indexed access return
  • Default type argument with a constraint
  • Constraints on type aliases
  • Array constraint and inference
  • Only constraint members are visible
  • T is assignable to its constraint
  • Indexing a tuple with number
  • Recursive conditional type that flattens arrays
  • Chained indexed access on a recursive interface
  • Recursive JSON type alias
  • Illegal direct self-reference in a union alias
  • Recursive tuple recursion with infer
  • keyof a string index signature
  • Indexed access types as annotations
  • Recursively unwrapping nested promises
  • Chained indexed access types
  • infer captures the first parameter type
  • Mapped type value substitution
  • Template literal types with Uppercase
  • Distribution requires a naked type parameter
  • Extract on a discriminated union
  • Constrained key generic narrows the return type
  • Inferring an array element type
  • Inferring a function's return type
  • When the infer pattern does not match
  • Inferring a parameter type
  • Where infer is allowed
  • Unwrapping a Promise with infer
  • Fallback branch returning T
  • Inferring the first tuple element
  • Tuple patterns and empty tuples
  • Distributive conditional types filtering a union
  • Disabling distribution with tuple wrapping
  • Filtering unions with distributive conditionals