Skip to content

Commit 0cb0cc9

Browse files
feat: add phone number validation (#28)
1 parent 8bf2927 commit 0cb0cc9

25 files changed

Lines changed: 862 additions & 16 deletions

.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,8 +59,8 @@ jobs:
5959
- name: Set up Rust toolchain
6060
uses: actions-rust-lang/setup-rust-toolchain@v1
6161
with:
62-
components: clippy, rustfmt
62+
components: clippy, rustfmt, rust-src
6363
target: wasm32-unknown-unknown
6464

6565
- name: Test
66-
run: cargo test --locked --release
66+
run: cargo test --all-features --locked --release

Cargo.lock

Lines changed: 153 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ email_address = { version = "0.2.9", default-features = false }
1414
fortifier = { path = "./packages/fortifier", version = "0.0.1" }
1515
fortifier-macros = { path = "./packages/fortifier-macros", version = "0.0.1" }
1616
indexmap = "2.12.0"
17+
phonenumber = "0.3.7"
1718
regex = "1.12.2"
1819
serde = "1.0.228"
1920
serde_json = "1.0.145"

book/src/SUMMARY.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
- [Validations](./validations/README.md)
1010
- [Email](./validations/email.md)
1111
- [Length](./validations/length.md)
12+
- [Phone Number](./validations/phone-number.md)
1213
- [Regex]()
1314
- [URL](./validations/url.md)
1415
- [Integrations]()

book/src/introduction.md

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,16 @@
22

33
Schema validation.
44

5-
- Synchronous and asynchronous validation
6-
- Enums and structs
5+
- Synchronous & asynchronous validation
6+
- Enums & structs
77
- Typed errors
8-
- Email, regex, URL and more
9-
- Support for Serde and Utoipa
8+
- Built-in validations
9+
- Email
10+
- Length
11+
- Phone number
12+
- Regex
13+
- URL
14+
- Support for Serde & Utoipa
1015

1116
## Credits
1217

book/src/validations/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,5 @@
22

33
- [Email](./email.md)
44
- [Length](./length.md)
5+
- [Phone Number](./phone-number.md)
56
- [URL](./url.md)

0 commit comments

Comments
 (0)