serv4rs 0.1.7

serv4rs is a powerful, pragmatic, and extremely fast web framework for Rust
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
use serv4rs::{reg_router, run};

#[rustfmt::skip]
pub fn config(cfg: &mut actix_web::web::ServiceConfig) {
    reg_router(cfg, "GET", "/1", || async { "Hey there! 啊啊送积分啦;送积分啦 1" }); 
    reg_router(cfg, "GET", "/2", || async { "Hey there! 啊啊送积分啦;送积分啦 2" }); 
    reg_router(cfg, "GET", "/3", || async { "Hey there! 啊啊送积分啦;送积分啦 3" }); 
    reg_router(cfg, "GET", "/4", || async { "Hey there! 啊啊送积分啦;送积分啦 4" });    
}

#[tokio::main]
async fn main() {
    run("serv4rs", |cfg| {
        config(cfg);
    })
    .await
}