|
use warp::{Filter, Rejection, Reply};
|
|
|
|
mod db;
|
|
mod users;
|
|
|
|
async fn hello() -> Result<impl Reply, Rejection> {
|
|
Ok("Hello!".to_string())
|
|
}
|
|
|
|
#[tokio::main]
|
|
async fn main() {
|
|
let hello = warp::any().and_then(hello);
|
|
warp::serve(hello).run(([127, 0, 0, 1], 8000)).await;
|
|
}
|