Expand description
§warp-embed
Serve embedded file with warp
ⓘ
use warp::Filter;
use rust_embed::RustEmbed;
#[derive(RustEmbed)]
#[folder = "data"]
struct Data;
let data_serve = warp_embed::embed(&Data);
Structs§
- Embed
Config - Embed serving configuration
Functions§
- embed
- Creates a
Filter
that serves embedded files at the basepath
joined by the request path. - embed_
one - Creates a
Filter
that always serves one embedded file - embed_
with_ config - Creates a
Filter
that serves embedded files at the basepath
joined by the request path with configuration.