diff --git a/README.md b/README.md index 11e2bc4f9..8afbe507f 100644 --- a/README.md +++ b/README.md @@ -2,11 +2,15 @@ > A collection of additional crates supporting [Actix Web]. + + [![CI](https://github.com/actix/actix-extras/actions/workflows/ci.yml/badge.svg)](https://github.com/actix/actix-extras/actions/workflows/ci.yml) [![codecov](https://codecov.io/gh/actix/actix-extras/branch/master/graph/badge.svg)](https://codecov.io/gh/actix/actix-extras) [![Chat on Discord](https://img.shields.io/discord/771444961383153695?label=chat&logo=discord)](https://discord.gg/5Ux4QGChWc) [![Dependency Status](https://deps.rs/repo/github/actix/actix-extras/status.svg)](https://deps.rs/repo/github/actix/actix-extras) + + ## Crates by @actix | Crate | | | diff --git a/actix-cors/README.md b/actix-cors/README.md index 7551215e9..ef40556cd 100644 --- a/actix-cors/README.md +++ b/actix-cors/README.md @@ -40,14 +40,14 @@ async fn index(req: HttpRequest) -> &'static str { async fn main() -> std::io::Result<()> { HttpServer::new(|| { let cors = Cors::default() - .allowed_origin("https://www.rust-lang.org") - .allowed_origin_fn(|origin, _req_head| { - origin.as_bytes().ends_with(b".rust-lang.org") - }) - .allowed_methods(vec!["GET", "POST"]) - .allowed_headers(vec![http::header::AUTHORIZATION, http::header::ACCEPT]) - .allowed_header(http::header::CONTENT_TYPE) - .max_age(3600); + .allowed_origin("https://www.rust-lang.org") + .allowed_origin_fn(|origin, _req_head| { + origin.as_bytes().ends_with(b".rust-lang.org") + }) + .allowed_methods(vec!["GET", "POST"]) + .allowed_headers(vec![http::header::AUTHORIZATION, http::header::ACCEPT]) + .allowed_header(http::header::CONTENT_TYPE) + .max_age(3600); App::new() .wrap(cors) diff --git a/actix-identity/README.md b/actix-identity/README.md index e373d80eb..4db84407a 100644 --- a/actix-identity/README.md +++ b/actix-identity/README.md @@ -2,11 +2,15 @@ > Identity management for Actix Web. + + [![crates.io](https://img.shields.io/crates/v/actix-identity?label=latest)](https://crates.io/crates/actix-identity) [![Documentation](https://docs.rs/actix-identity/badge.svg?version=0.6.0)](https://docs.rs/actix-identity/0.6.0) ![Apache 2.0 or MIT licensed](https://img.shields.io/crates/l/actix-identity) [![Dependency Status](https://deps.rs/crate/actix-identity/0.6.0/status.svg)](https://deps.rs/crate/actix-identity/0.6.0) + + ## Documentation & community resources - [API Documentation](https://docs.rs/actix-identity) diff --git a/actix-limitation/README.md b/actix-limitation/README.md index 7c4ba182b..61296db96 100644 --- a/actix-limitation/README.md +++ b/actix-limitation/README.md @@ -3,11 +3,15 @@ > Rate limiter using a fixed window counter for arbitrary keys, backed by Redis for Actix Web. > Originally based on . + + [![crates.io](https://img.shields.io/crates/v/actix-limitation?label=latest)](https://crates.io/crates/actix-limitation) [![Documentation](https://docs.rs/actix-limitation/badge.svg?version=0.5.1)](https://docs.rs/actix-limitation/0.5.1) ![Apache 2.0 or MIT licensed](https://img.shields.io/crates/l/actix-limitation) [![Dependency Status](https://deps.rs/crate/actix-limitation/0.5.1/status.svg)](https://deps.rs/crate/actix-limitation/0.5.1) + + ## Examples ```toml diff --git a/actix-protobuf/README.md b/actix-protobuf/README.md index dfb34a799..a273130cf 100644 --- a/actix-protobuf/README.md +++ b/actix-protobuf/README.md @@ -2,11 +2,15 @@ > Protobuf payload extractor for Actix Web. + + [![crates.io](https://img.shields.io/crates/v/actix-protobuf?label=latest)](https://crates.io/crates/actix-protobuf) [![Documentation](https://docs.rs/actix-protobuf/badge.svg?version=0.10.0)](https://docs.rs/actix-protobuf/0.10.0) ![Apache 2.0 or MIT licensed](https://img.shields.io/crates/l/actix-protobuf) [![Dependency Status](https://deps.rs/crate/actix-protobuf/0.10.0/status.svg)](https://deps.rs/crate/actix-protobuf/0.10.0) + + ## Documentation & Resources - [API Documentation](https://docs.rs/actix-protobuf) diff --git a/actix-redis/CHANGES.md b/actix-redis/CHANGES.md index 11dc47d47..672db04ab 100644 --- a/actix-redis/CHANGES.md +++ b/actix-redis/CHANGES.md @@ -86,8 +86,7 @@ ## 0.9.0-alpha.2 -- Add `cookie_http_only` functionality to RedisSession builder, setting this - to false allows JavaScript to access cookies. Defaults to true. +- Add `cookie_http_only` functionality to RedisSession builder, setting this to false allows JavaScript to access cookies. Defaults to true. - Change type of parameter of ttl method to u32. - Update `actix` to 0.10.0-alpha.3 - Update `tokio-util` to 0.3 @@ -116,8 +115,7 @@ ## 0.7.0 - 2019-09-25 -- added cache_keygen functionality to RedisSession builder, enabling support for - customizable cache key creation +- added cache_keygen functionality to RedisSession builder, enabling support for customizable cache key creation ## 0.6.1 - 2019-07-19 @@ -127,12 +125,7 @@ ## 0.6.0 - 2019-07-08 - actix-web 1.0.0 compatibility -- Upgraded logic that evaluates session state, including new SessionStatus field, - and introduced `session.renew()` and `session.purge()` functionality. - Use `renew()` to cycle the session key at successful login. `renew()` keeps a - session's state while replacing the old cookie and session key with new ones. - Use `purge()` at logout to invalidate the session cookie and remove the - session's redis cache entry. +- Upgraded logic that evaluates session state, including new SessionStatus field, and introduced `session.renew()` and `session.purge()` functionality. Use `renew()` to cycle the session key at successful login. `renew()` keeps a session's state while replacing the old cookie and session key with new ones. Use `purge()` at logout to invalidate the session cookie and remove the session's redis cache entry. ## 0.5.1 - 2018-08-02 diff --git a/actix-redis/README.md b/actix-redis/README.md index bf5827c37..af4fbaaaa 100644 --- a/actix-redis/README.md +++ b/actix-redis/README.md @@ -2,11 +2,15 @@ > Actor-based Redis client. + + [![crates.io](https://img.shields.io/crates/v/actix-redis?label=latest)](https://crates.io/crates/actix-redis) [![Documentation](https://docs.rs/actix-redis/badge.svg?version=0.13.0)](https://docs.rs/actix-redis/0.13.0) ![Apache 2.0 or MIT licensed](https://img.shields.io/crates/l/actix-redis) [![Dependency Status](https://deps.rs/crate/actix-redis/0.13.0/status.svg)](https://deps.rs/crate/actix-redis/0.13.0) + + ## Documentation & Resources - [API Documentation](https://docs.rs/actix-redis) diff --git a/actix-session/CHANGES.md b/actix-session/CHANGES.md index d97f3c6b1..4692f7785 100644 --- a/actix-session/CHANGES.md +++ b/actix-session/CHANGES.md @@ -175,10 +175,7 @@ ## 0.2.0 - 2019-07-08 -- Enhanced `actix-session` to facilitate state changes. Use `Session.renew()` - at successful login to cycle a session (new key/cookie but keeps state). - Use `Session.purge()` at logout to invalid a session cookie (and remove - from redis cache, if applicable). +- Enhanced `actix-session` to facilitate state changes. Use `Session.renew()` at successful login to cycle a session (new key/cookie but keeps state). Use `Session.purge()` at logout to invalid a session cookie (and remove from redis cache, if applicable). ## 0.1.1 - 2019-06-03 diff --git a/actix-session/README.md b/actix-session/README.md index 57103d1ec..9e14caef1 100644 --- a/actix-session/README.md +++ b/actix-session/README.md @@ -2,11 +2,15 @@ > Session management for Actix Web. + + [![crates.io](https://img.shields.io/crates/v/actix-session?label=latest)](https://crates.io/crates/actix-session) [![Documentation](https://docs.rs/actix-session/badge.svg?version=0.8.0)](https://docs.rs/actix-session/0.8.0) ![Apache 2.0 or MIT licensed](https://img.shields.io/crates/l/actix-session) [![Dependency Status](https://deps.rs/crate/actix-session/0.8.0/status.svg)](https://deps.rs/crate/actix-session/0.8.0) + + ## Documentation & Resources - [API Documentation](https://docs.rs/actix-session) diff --git a/actix-settings/README.md b/actix-settings/README.md index cbe71fa90..659871edc 100644 --- a/actix-settings/README.md +++ b/actix-settings/README.md @@ -2,11 +2,15 @@ > Easily manage Actix Web's settings from a TOML file and environment variables. + + [![crates.io](https://img.shields.io/crates/v/actix-settings?label=latest)](https://crates.io/crates/actix-settings) [![Documentation](https://docs.rs/actix-settings/badge.svg?version=0.7.1)](https://docs.rs/actix-settings/0.7.1) ![Apache 2.0 or MIT licensed](https://img.shields.io/crates/l/actix-settings) [![Dependency Status](https://deps.rs/crate/actix-settings/0.7.1/status.svg)](https://deps.rs/crate/actix-settings/0.7.1) + + ## Documentation & Resources - [API Documentation](https://docs.rs/actix-settings) diff --git a/actix-web-httpauth/README.md b/actix-web-httpauth/README.md index d134fcd29..85e1cc55f 100644 --- a/actix-web-httpauth/README.md +++ b/actix-web-httpauth/README.md @@ -2,11 +2,15 @@ > HTTP authentication schemes for [Actix Web](https://actix.rs). + + [![crates.io](https://img.shields.io/crates/v/actix-web-httpauth?label=latest)](https://crates.io/crates/actix-web-httpauth) [![Documentation](https://docs.rs/actix-web-httpauth/badge.svg?version=0.8.1)](https://docs.rs/actix-web-httpauth/0.8.1) ![Apache 2.0 or MIT licensed](https://img.shields.io/crates/l/actix-web-httpauth) [![Dependency Status](https://deps.rs/crate/actix-web-httpauth/0.8.1/status.svg)](https://deps.rs/crate/actix-web-httpauth/0.8.1) + + ## Documentation & Resources - [API Documentation](https://docs.rs/actix-web-httpauth/) diff --git a/actix-ws/README.md b/actix-ws/README.md index 558b45e9d..72390f889 100644 --- a/actix-ws/README.md +++ b/actix-ws/README.md @@ -2,11 +2,15 @@ > WebSockets for Actix Web, without actors. + + [![crates.io](https://img.shields.io/crates/v/actix-ws?label=latest)](https://crates.io/crates/actix-ws) [![Documentation](https://docs.rs/actix-ws/badge.svg?version=0.2.0)](https://docs.rs/actix-ws/0.2.0) ![Apache 2.0 or MIT licensed](https://img.shields.io/crates/l/actix-ws) [![Dependency Status](https://deps.rs/crate/actix-ws/0.2.0/status.svg)](https://deps.rs/crate/actix-ws/0.2.0) + + ## Documentation & Resources - [API Documentation](https://docs.rs/actix-ws) diff --git a/justfile b/justfile index d92f09c1e..4eea8add7 100644 --- a/justfile +++ b/justfile @@ -3,6 +3,7 @@ _list: # Format workspace. fmt: + cargo +nightly fmt npx -y prettier --write $(fd --hidden --extension=yml --extension=md) # Update READMEs from crate root documentation.