Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

awesome-validator

Package Overview
Dependencies
Maintainers
1
Versions
34
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

awesome-validator

Awesome validator for node or browser.

  • 3.2.0
  • unpublished
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
Maintainers
1
Weekly downloads
 
Created
Source

Awesome Validator

Awesome validator for node or browser.

NPM Version Downloads MIT License

Build Status Build status Coverage Status

Code Climate Test Coverage Issue Count

Dependencies Status devDependencies Status peerDependencies Status

Semantic Release Commitizen friendly Average time to resolve an issue Percentage of issues still open Gitter

NPM

Server-side

Install the library with npm install --save awesome-validator

var validator = require('awesome-validator').validator;

validator.notEmpty().stringType().validate('foo'); //=> true

ES6

import validator from 'awesome-validator';

validator.notEmpty().stringType().validate('foo'); //=> true

Or, import only a subset of the library:

import StringType from 'awesome-validator/lib/rules/string-type';

new StringType().validate('foo'); //=> true

Typescript

import { validator } from 'awesome-validator';

validator.notEmpty().stringType().validate('foo'); //=> true

Or, import only a subset of the library:

import { StringType } from 'awesome-validator/lib/rules/string-type';

new StringType().validate('foo'); //=> true

Client-side usage

The library can be loaded either as a standalone script, or through an AMD-compatible loader

<script type="text/javascript" src="awesome-validator.min.js"></script>
<script type="text/javascript">
    validator.notEmpty().stringType().validate('foo'); //=> true
</script>

Validators

Keywords

FAQs

Package last updated on 26 Jan 2018

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