Intermediate TypeScript
Q78 / 100

What is the difference between "interface A extends B" and "type A = B & C"?

Correct! Well done.

Incorrect.

The correct answer is B) Both can combine type shapes, but interfaces use "extends" for inheritance while type aliases use intersection ("&") to combine types

B

Correct Answer

Both can combine type shapes, but interfaces use "extends" for inheritance while type aliases use intersection ("&") to combine types

Explanation

Interface inheritance via extends and type intersection via & both combine multiple shapes into one, though they have different merging semantics for conflicting members.

Progress
78/100