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

open-form-validators

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

open-form-validators

Validator package for OpenForm

  • 1.5.0
  • latest
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

OpenForm - Validators

Validator library for OpenForm. It supports several validators such as minValue, maxValue, minLength, maxLength, *minDate, *maxDate, earliestToday, email and also combinations.

Usage

import { validate } from 'open-form-validators';

const result = validate('100', 'minValue60,maxValue100');

If you want to use the validationKeys to write your validation predicate:

import { validate, VALIDATION_KEYS } from 'open-form-validators';

const result = validate(
  '100',
  `${VALIDATION_KEYS.MIN_VALUE}60,${VALIDATION_KEYS.MAX_VALUE}100`
);

Keywords

FAQs

Package last updated on 05 Mar 2020

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