[F] validateDecoratorTarget
Validate the decorator target is matching the expected value.
Type Parameters
Type Parameter |
---|
K extends TypeKind |
Parameters
Parameter | Type | Description |
---|---|---|
context | DecoratorContext | |
target | Type | |
decoratorName | string | |
expectedType | K | readonly K [] |
Returns
target is K extends "Any" ? Type : Type & Object