class-validator icon indicating copy to clipboard operation
class-validator copied to clipboard

fix: @IsMACAddress({}) optionsArg set to any type in VSCode

Open carlocorradini opened this issue 2 years ago • 0 comments

Description

When using @IsMACAddress({}) decorator the optionsArg is set to any in VSCode even though isMacAddress.d.ts has the correct type: image

I don't know if this is related to VSCode only or is a more general issue.

Minimal code-snippet showcasing the problem

class Test {
  // {} does not show any type hints
  @IsMACAddress({})
  address!: string;
}

Expected behavior

optionsArgs showing ValidatorJS.IsMACAddressOptions options.

Actual behavior

No type hint and optionsArg is set to any: image

carlocorradini avatar May 20 '22 16:05 carlocorradini