Skip to content

NdumaTo/validity-text-length

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Text length validator

Validity style validator to ensure visible length of strings. Supports emojis and other graphemes through grapheme splitter

Installation

npm install validity-text-length --save

yarn add validity-text-length

Usage

Below is example usage of the text length validator:

const textLength = require('validity-text-length),
schemata = require('schemata)

var schema = schemata (
  {
    firstName:
    {
      type: String
      , validators: { [ textLength(1, 10) ] }
    }
  }
)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors