diff options
author | Vika <vika@fireburn.ru> | 2022-05-07 20:28:43 +0300 |
---|---|---|
committer | Vika <vika@fireburn.ru> | 2022-05-07 20:28:43 +0300 |
commit | 139b7ec10bc7f08dae9bd57eef8eff73fbb22061 (patch) | |
tree | 973c4d903e731cb5e38b682f22c38c3da1dbcd92 /src/lib.rs | |
parent | 0679de841840c74ab49f54905783fac1faf028e1 (diff) | |
download | kittybox-139b7ec10bc7f08dae9bd57eef8eff73fbb22061.tar.zst |
Split into different crates
Templates and utility types are now separate crates to speed up compilation, linting and potential reuse/replacement. Potentially more crates could be split out/modularized, resulting in speedups, smaller binaries (whenever features are excluded) and even more reuse capabilities.
Diffstat (limited to 'src/lib.rs')
-rw-r--r-- | src/lib.rs | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/src/lib.rs b/src/lib.rs index 2709022..9d4335a 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -31,15 +31,6 @@ pub mod util { }) } - pub fn template<R>( - template: R - ) -> impl warp::Reply - where - R: markup::Render + std::fmt::Display - { - warp::reply::html(template.to_string()) - } - pub fn parse_accept() -> impl Filter<Extract = (http_types::Mime,), Error = warp::Rejection> + Copy { warp::header::value("Accept").and_then(|accept: warp::http::HeaderValue| async move { let mut accept: http_types::content::Accept = { |