Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/realign/n-validator
https://github.com/realign/n-validator
Last synced: 8 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/realign/n-validator
- Owner: ReAlign
- Created: 2017-12-04T12:12:22.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2017-12-18T01:00:34.000Z (almost 7 years ago)
- Last Synced: 2024-10-28T15:40:51.498Z (18 days ago)
- Language: JavaScript
- Size: 43 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# n-validator
[![codecov][codecov-image]][codecov-url][codecov-url]: https://codecov.io/gh/ReAlign/n-validator
[codecov-image]: https://codecov.io/gh/ReAlign/n-validator/branch/master/graph/badge.svg## Validator
| Method | Description |
| --- | --- |
| isInt(str, [, options]) | check if the variable is an integer. |
| isFloat(str, [, options]) | check if the variable is a float. |
| isDate(str, [, options]) | check if the string is a date string. |
| isDateTime(str, [, options]) | check if the string is a date-time string. |
| isBoolean(val, [, options]) | check if the variable is a boolean. |
| isLength(str, [, options]) | check if the string's length falls in a range. ( [min, max] ) |
| isRequired(str) | check if the variable required. |## todo
* [ ] isFloat, decimal digits(0.10: 2?1)
* [ ] number strictMode
* [ ] date stamp