Intermediate
TypeScript
Q58 / 100
What does the conditional type "T extends U ? X : Y" do?
Correct! Well done.
Incorrect.
The correct answer is B) Resolves to type X if T is assignable to U, otherwise resolves to Y
B
Correct Answer
Resolves to type X if T is assignable to U, otherwise resolves to Y
Explanation
Conditional types let you choose between two types based on a type-level assignability check, similar to a ternary at the type level.
Progress
58/100