Macro html_file

Source
macro_rules! html_file {
    ($file_name:expr, $body:expr) => { ... };
    ($file_name:expr, $body:expr, [ $( ($key:expr, $value:expr) ),* $(,)? ]) => { ... };
}
Expand description

Produces OK 200 response with HTML file body

§Examples

§Default usage

 use volga::html_file;
 use tokio::fs::File;

 let index_name = "index.html";
 let index_file = File::open(index_name).await?;
 html_file!(index_name, index_file);