const metadataKey = "metadataKey";
class User
{
@Reflect.metadata(metadataKey, 1)
name: string;
@Reflect.metadata(metadataKey, 2)
age: number;
}
getPropertyDecorators(User); // I hope it can return [1, 2]
I hope the function getPropertyDecorators doesn't need to create an instance of User.
Aucun commentaire:
Enregistrer un commentaire