| Crates.io | hypo-serve |
| lib.rs | hypo-serve |
| version | 0.1.0 |
| created_at | 2025-10-31 10:40:39.386072+00 |
| updated_at | 2025-10-31 10:40:39.386072+00 |
| description | Hyper text transfar protocol written in rust. |
| homepage | |
| repository | https://github.com/themahikaishar/hypo-serve |
| max_upload_size | |
| id | 1909845 |
| size | 21,820 |
Hyper text transfar protocol written in rust.
use hypo_serve::{HypoServe, Router};
fn main() {
let mut router = Router::new();
router.get("/", |_req, res| {
res.html("<h1>Hello world kahin hoilm.</h1>");
});
router.get("/hello", |_req, res| res.json("hello"));
router.get("/users/:userId", |req, res| {
res.json(&format!("userId --> {:?}, {:?}", req.params, req.query));
});
let mut server = HypoServe::new(true);
server.add_router(router);
println!("Listening on http://127.0.0.1:3000");
server.listen("127.0.0.1:3000").unwrap();
}
Contributions are welcome! I would like you to contribute in this project.
This project is in its early stages, and there are many missing features that need implementation. Check the Issues section for a list of features, enhancements, and bug fixes that are planned.
see the LICENSE file for details.