Crates.io | validate |
lib.rs | validate |
version | 0.6.1 |
source | src |
created_at | 2015-05-23 22:35:08.741431 |
updated_at | 2017-10-16 23:23:30.850295 |
description | A library to easily validate user input |
homepage | https://github.com/fuchsnj/validate |
repository | https://github.com/fuchsnj/validate |
max_upload_size | |
id | 2183 |
size | 8,138 |
A library to easily validate user input
Add this to your Cargo.toml
:
[dependencies]
validate = "*"
and this to your crate root:
extern crate validate;
use validate::*;
assert!(email().validate(&"test@domain.com").is_ok());
assert!(bound(..3).validate(&2).is_ok())