Skip to content

Commit

Permalink
Improve docs.rs documentation (#6)
Browse files Browse the repository at this point in the history
  • Loading branch information
ranger-ross authored Jul 6, 2024
1 parent 79f1ff2 commit 280f296
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 4 deletions.
5 changes: 4 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "actix-web-validation"
description = "A common validation interface for actix-web applications"
version = "0.1.0"
version = "0.1.1"
edition = "2021"
authors = ["Ross Sullivan <rosssullivan101@gmail.com>"]
repository = "https://github.com/ranger-ross/actix-web-validation"
Expand All @@ -23,3 +23,6 @@ validator = ["dep:validator"]
# Use garde crate (https://github.com/jprochazk/garde) as the validation implmentation
garde = ["dep:garde"]

[package.metadata.docs.rs]
all-features = true

9 changes: 6 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
# Actix Web Validation

> [!WARNING]
> This library is currently in early access and may recieve breaking changes. Use at your own risk.
Request validation for actix-web.


#### WARNING

This library is currently in early access and may recieve breaking changes.


## Supported Validation Libraries

* [validator](https://github.com/Keats/validator)
Expand Down
3 changes: 3 additions & 0 deletions src/garde.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
//! Validation for the [garde](https://docs.rs/garde/latest/garde) crate.
//! Requires the `garde` feature flag
use ::garde::Validate;
use actix_web::dev::{ServiceFactory, ServiceRequest};
use actix_web::http::StatusCode;
Expand Down
3 changes: 3 additions & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,6 @@
pub mod garde;
#[cfg(feature = "validator")]
pub mod validator;

#[cfg(feature = "docsrs")]
compile_error!("doc");
3 changes: 3 additions & 0 deletions src/validator.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
//! Validation for the [validator](https://docs.rs/validator/latest/validator) crate.
//! Requires the `validator` feature flag
use ::validator::Validate;
use actix_web::dev::{ServiceFactory, ServiceRequest};
use actix_web::http::StatusCode;
Expand Down

0 comments on commit 280f296

Please sign in to comment.