Search Docs
Loading...
Skip to content

Type Alias: InferComponentType

type InferComponentType<A> = A extends UIArea ? OrderComponentFor<A> : A extends UIArea[] ? OrderComponentFor<A[number]> : OrderComponent;

Infers the component type from a UI area specifier.

  • Single area: returns area-specific component type
  • Array of areas: returns union of component types
  • Glob pattern: returns base OrderComponent (all IDs)

Type Parameters#

Type Parameter
A extends UIAreaSpecifier