pub trait RouteDef {
// Required method
fn call(
&self,
request: Request,
) -> BoxFuture<'static, Result<String, String>>;
}Expand description
§RouteDef
This trait creates a helpful function that can convert an asynchrynous function without much user input.
This cleans up the API quite a bit, only requiring the user to Box the function they want to use.
Hopefully I figure out macros soon so I can simplify the whole process further to a single macro.