How do you prevent distribution in a conditional type?

TypeScript Professional Hard

TypeScript Professional — Hard

How do you prevent distribution in a conditional type?

Key points

  • Wrapping the type parameter in a tuple prevents unwanted distribution
  • Using `extends

Ready to go further?

Related questions