Skip to content

Latest commit

 

History

2 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 

Repository files navigation

Express in Rust

Purpose

My purpose for this project was to implement a Web Server from scratch while mantaining the ExpressJS API

Code Example

fn main() {
    let mut server = Server::new();

    server.get("/lol", |_: Request, _: Response| {
        println!("It actually works")
    });
    server.get("/samuel", |_: Request, mut res: Response| {
        res.status(400).send("<h1>sa</h1>")
    });

    server.listen(5000, || println!("Server Listening at: {}", 5000));
}

About

A test to copy ExpressJS API into a rust web server

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages