API Reference / @evolu/common / Types / IsBranded

Type Alias: IsBranded<T>

type IsBranded<T> = T extends Brand<string> ? true : false;

Defined in: packages/common/src/Types.ts:155

Determines whether a type T is a branded type.

Works with any base type intersected with a Brand.

Examples

  • IsBranded<string> -> false
  • IsBranded<string & Brand<"X">> -> true

Type Parameters

Type Parameter
T

Was this page helpful?