aboutsummaryrefslogtreecommitdiffstats
path: root/README.md
diff options
context:
space:
mode:
Diffstat (limited to 'README.md')
-rw-r--r--README.md10
1 files changed, 10 insertions, 0 deletions
diff --git a/README.md b/README.md
index 3a8aa0c..bbbe4de 100644
--- a/README.md
+++ b/README.md
@@ -151,6 +151,16 @@ Examples:
#[validate(regex = "ALLOWED_USERNAMES_RE"))]
```
+### credit\_card
+Test whetever the string is a valid credit card number. To use this validator,
+you must enable the `credit_cards` feature for the `validator` crate.
+
+Examples:
+
+```rust
+#[validate(credit_card)]
+```
+
### custom
Calls one of your function to do a custom validation.
The field will be given as parameter and it should return a `Option<String>` representing the error code,