New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

class-validator-extended

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

class-validator-extended

Additional decorator and non-decorator based validation for class-validator.

  • 0.0.2-beta
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
5.3K
increased by19.56%
Maintainers
1
Weekly downloads
 
Created
Source

npm GitHub Workflow Status requires.io Codecov npm bundle size Snyk Vulnerabilities for npm package

class-validator-extended

Additional decorator and non-decorator based validation for class-validator.

Validation decorators

For detailed information please read the API docs.

DecoratorDescription
Array
@ArrayMonotonic(options?)Checks if the given value is an array sorted in either (strictly) ascending or (strictly) descending order.
BigInt
@IsBigInt(options?)Checks if the given value is a BigInt.
@MaxBigInt(maximum, options?)Checks if the given value is a BigInt not greater than maximum.
@MinBigInt(minimum, options?)Checks if the given value is a BigInt not less than minimum.
@NegativeBigInt(options?)Checks if the given value is a BigInt less than zero.
@PositiveBigInt(options?)Checks if the given value is a BigInt greater than zero.
Date
@FutureDate(options?)Checks if the given value is a Date object in the future.
@PastDate(options?)Checks if the given value is a Date object in the past.
Dayjs
@FutureDayjs(options?)Checks if the given value is a Dayjs object in the future.
@IsDayjs(options?)Checks if the given value is a Dayjs object.
@MaxDayjs(maximum. options?)Checks if the given value is a Dayjs object not later than maximum.
@MinDayjs(minimum, options?)Checks if the given value is a Dayjs object not earlier than minimum.
@PastDayjs(options?)Checks if the given value is a Dayjs object in the past.
Map
@IsMap(options?)Checks if the given value is a Map.
@MapContains(required, options?)Checks if the given value is a Map and contains all required values.
@MapContainsKeys(required, options?)Checks if the given value is a Map and contains all required keys.
@MapMaxSize(maximum, options?)Checks if the given value is a Map with no more than maximum entries.
@MapMinSize(minimum, options?)Checks if the given value is a Map with no fewer than minimum entries.
@MapNotContains(forbidden, options?)Checks if the given value is a Map which does not contain any of the forbidden values.
@MapNotContainsKeys(forbidden, options?)Checks if the given value is a Map which does not contain any of the forbidden keys.
@MapNotEmpty(options?)Checks if the given value is a Map with at least one entry.
@MapUnique(projection, options?)Checks if the given value is a Map without duplicates with regard to the given projection.
@MapUniqueKeys(projection, options?)Checks if the given value is a Map whose keys are all unique with regard to the given projection.
Set
@IsSet(options?)Checks if the given value is a Set.
@SetContains(required, options?)Checks if the given value is a Set and contains all required values.
@SetMaxSize(maximum, options?)Checks if the given value is a Set with no more than maximum values.
@SetMinSize(minimum, options?)Checks if the given value is a Set with no fewer than minimum values.
@SetNotContains(forbidden, options?)Checks if the given value is a Set which does not contain any of the forbidden values.
@SetNotEmpty(options?)Checks if the given value is a Set with at least one value.
@SetUnique(projection, options?)Checks if the given value is a Set without duplicate values with regard to the given projection
String
@IsTimezone(options?)Checks if the given value is a valid timezone string.

Keywords

FAQs

Package last updated on 10 Jan 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc