1
0
mirror of https://github.com/actix/actix-extras.git synced 2024-11-27 09:12:57 +01:00

chore: fmt markdowns

This commit is contained in:
Rob Ede 2024-01-06 21:08:09 +00:00
parent 0c859a96c8
commit 320cbebc7e
No known key found for this signature in database
GPG Key ID: 97C636207D3EF933
13 changed files with 49 additions and 22 deletions

View File

@ -2,11 +2,15 @@
> A collection of additional crates supporting [Actix Web]. > A collection of additional crates supporting [Actix Web].
<!-- prettier-ignore-start -->
[![CI](https://github.com/actix/actix-extras/actions/workflows/ci.yml/badge.svg)](https://github.com/actix/actix-extras/actions/workflows/ci.yml) [![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) [![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) [![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) [![Dependency Status](https://deps.rs/repo/github/actix/actix-extras/status.svg)](https://deps.rs/repo/github/actix/actix-extras)
<!-- prettier-ignore-end -->
## Crates by @actix ## Crates by @actix
| Crate | | | | Crate | | |

View File

@ -40,14 +40,14 @@ async fn index(req: HttpRequest) -> &'static str {
async fn main() -> std::io::Result<()> { async fn main() -> std::io::Result<()> {
HttpServer::new(|| { HttpServer::new(|| {
let cors = Cors::default() let cors = Cors::default()
.allowed_origin("https://www.rust-lang.org") .allowed_origin("https://www.rust-lang.org")
.allowed_origin_fn(|origin, _req_head| { .allowed_origin_fn(|origin, _req_head| {
origin.as_bytes().ends_with(b".rust-lang.org") origin.as_bytes().ends_with(b".rust-lang.org")
}) })
.allowed_methods(vec!["GET", "POST"]) .allowed_methods(vec!["GET", "POST"])
.allowed_headers(vec![http::header::AUTHORIZATION, http::header::ACCEPT]) .allowed_headers(vec![http::header::AUTHORIZATION, http::header::ACCEPT])
.allowed_header(http::header::CONTENT_TYPE) .allowed_header(http::header::CONTENT_TYPE)
.max_age(3600); .max_age(3600);
App::new() App::new()
.wrap(cors) .wrap(cors)

View File

@ -2,11 +2,15 @@
> Identity management for Actix Web. > Identity management for Actix Web.
<!-- prettier-ignore-start -->
[![crates.io](https://img.shields.io/crates/v/actix-identity?label=latest)](https://crates.io/crates/actix-identity) [![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) [![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) ![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) [![Dependency Status](https://deps.rs/crate/actix-identity/0.6.0/status.svg)](https://deps.rs/crate/actix-identity/0.6.0)
<!-- prettier-ignore-end -->
## Documentation & community resources ## Documentation & community resources
- [API Documentation](https://docs.rs/actix-identity) - [API Documentation](https://docs.rs/actix-identity)

View File

@ -3,11 +3,15 @@
> Rate limiter using a fixed window counter for arbitrary keys, backed by Redis for Actix Web. > Rate limiter using a fixed window counter for arbitrary keys, backed by Redis for Actix Web.
> Originally based on <https://github.com/fnichol/limitation>. > Originally based on <https://github.com/fnichol/limitation>.
<!-- prettier-ignore-start -->
[![crates.io](https://img.shields.io/crates/v/actix-limitation?label=latest)](https://crates.io/crates/actix-limitation) [![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) [![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) ![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) [![Dependency Status](https://deps.rs/crate/actix-limitation/0.5.1/status.svg)](https://deps.rs/crate/actix-limitation/0.5.1)
<!-- prettier-ignore-end -->
## Examples ## Examples
```toml ```toml

View File

@ -2,11 +2,15 @@
> Protobuf payload extractor for Actix Web. > Protobuf payload extractor for Actix Web.
<!-- prettier-ignore-start -->
[![crates.io](https://img.shields.io/crates/v/actix-protobuf?label=latest)](https://crates.io/crates/actix-protobuf) [![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) [![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) ![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) [![Dependency Status](https://deps.rs/crate/actix-protobuf/0.10.0/status.svg)](https://deps.rs/crate/actix-protobuf/0.10.0)
<!-- prettier-ignore-end -->
## Documentation & Resources ## Documentation & Resources
- [API Documentation](https://docs.rs/actix-protobuf) - [API Documentation](https://docs.rs/actix-protobuf)

View File

@ -86,8 +86,7 @@
## 0.9.0-alpha.2 ## 0.9.0-alpha.2
- Add `cookie_http_only` functionality to RedisSession builder, setting this - Add `cookie_http_only` functionality to RedisSession builder, setting this to false allows JavaScript to access cookies. Defaults to true.
to false allows JavaScript to access cookies. Defaults to true.
- Change type of parameter of ttl method to u32. - Change type of parameter of ttl method to u32.
- Update `actix` to 0.10.0-alpha.3 - Update `actix` to 0.10.0-alpha.3
- Update `tokio-util` to 0.3 - Update `tokio-util` to 0.3
@ -116,8 +115,7 @@
## 0.7.0 - 2019-09-25 ## 0.7.0 - 2019-09-25
- added cache_keygen functionality to RedisSession builder, enabling support for - added cache_keygen functionality to RedisSession builder, enabling support for customizable cache key creation
customizable cache key creation
## 0.6.1 - 2019-07-19 ## 0.6.1 - 2019-07-19
@ -127,12 +125,7 @@
## 0.6.0 - 2019-07-08 ## 0.6.0 - 2019-07-08
- actix-web 1.0.0 compatibility - actix-web 1.0.0 compatibility
- Upgraded logic that evaluates session state, including new SessionStatus field, - 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.
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 ## 0.5.1 - 2018-08-02

View File

@ -2,11 +2,15 @@
> Actor-based Redis client. > Actor-based Redis client.
<!-- prettier-ignore-start -->
[![crates.io](https://img.shields.io/crates/v/actix-redis?label=latest)](https://crates.io/crates/actix-redis) [![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) [![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) ![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) [![Dependency Status](https://deps.rs/crate/actix-redis/0.13.0/status.svg)](https://deps.rs/crate/actix-redis/0.13.0)
<!-- prettier-ignore-end -->
## Documentation & Resources ## Documentation & Resources
- [API Documentation](https://docs.rs/actix-redis) - [API Documentation](https://docs.rs/actix-redis)

View File

@ -175,10 +175,7 @@
## 0.2.0 - 2019-07-08 ## 0.2.0 - 2019-07-08
- Enhanced `actix-session` to facilitate state changes. Use `Session.renew()` - 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).
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 ## 0.1.1 - 2019-06-03

View File

@ -2,11 +2,15 @@
> Session management for Actix Web. > Session management for Actix Web.
<!-- prettier-ignore-start -->
[![crates.io](https://img.shields.io/crates/v/actix-session?label=latest)](https://crates.io/crates/actix-session) [![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) [![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) ![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) [![Dependency Status](https://deps.rs/crate/actix-session/0.8.0/status.svg)](https://deps.rs/crate/actix-session/0.8.0)
<!-- prettier-ignore-end -->
## Documentation & Resources ## Documentation & Resources
- [API Documentation](https://docs.rs/actix-session) - [API Documentation](https://docs.rs/actix-session)

View File

@ -2,11 +2,15 @@
> Easily manage Actix Web's settings from a TOML file and environment variables. > Easily manage Actix Web's settings from a TOML file and environment variables.
<!-- prettier-ignore-start -->
[![crates.io](https://img.shields.io/crates/v/actix-settings?label=latest)](https://crates.io/crates/actix-settings) [![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) [![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) ![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) [![Dependency Status](https://deps.rs/crate/actix-settings/0.7.1/status.svg)](https://deps.rs/crate/actix-settings/0.7.1)
<!-- prettier-ignore-end -->
## Documentation & Resources ## Documentation & Resources
- [API Documentation](https://docs.rs/actix-settings) - [API Documentation](https://docs.rs/actix-settings)

View File

@ -2,11 +2,15 @@
> HTTP authentication schemes for [Actix Web](https://actix.rs). > HTTP authentication schemes for [Actix Web](https://actix.rs).
<!-- prettier-ignore-start -->
[![crates.io](https://img.shields.io/crates/v/actix-web-httpauth?label=latest)](https://crates.io/crates/actix-web-httpauth) [![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) [![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) ![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) [![Dependency Status](https://deps.rs/crate/actix-web-httpauth/0.8.1/status.svg)](https://deps.rs/crate/actix-web-httpauth/0.8.1)
<!-- prettier-ignore-end -->
## Documentation & Resources ## Documentation & Resources
- [API Documentation](https://docs.rs/actix-web-httpauth/) - [API Documentation](https://docs.rs/actix-web-httpauth/)

View File

@ -2,11 +2,15 @@
> WebSockets for Actix Web, without actors. > WebSockets for Actix Web, without actors.
<!-- prettier-ignore-start -->
[![crates.io](https://img.shields.io/crates/v/actix-ws?label=latest)](https://crates.io/crates/actix-ws) [![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) [![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) ![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) [![Dependency Status](https://deps.rs/crate/actix-ws/0.2.0/status.svg)](https://deps.rs/crate/actix-ws/0.2.0)
<!-- prettier-ignore-end -->
## Documentation & Resources ## Documentation & Resources
- [API Documentation](https://docs.rs/actix-ws) - [API Documentation](https://docs.rs/actix-ws)

View File

@ -3,6 +3,7 @@ _list:
# Format workspace. # Format workspace.
fmt: fmt:
cargo +nightly fmt
npx -y prettier --write $(fd --hidden --extension=yml --extension=md) npx -y prettier --write $(fd --hidden --extension=yml --extension=md)
# Update READMEs from crate root documentation. # Update READMEs from crate root documentation.