Type Alias: ReplaceTypeDistributed<T, ConditionType, ReplacementType>
ReplaceTypeDistributed<
T,ConditionType,ReplacementType> =TextendsConditionType?ReplacementType:T
Defined in: src/sdk/utils/types/UtilityTypes.ts:117
Conditionally replaces a type with another one if the former extends a specified type. The type to replace is distributed if it is a union.
Type Parameters
| Type Parameter | Description |
|---|---|
T | The type to replace. |
ConditionType | The type that T must extend in order to be replaced. |
ReplacementType | The type with which to replace T if it extends ConditionType. |