Crates.io | krustie |
lib.rs | krustie |
version | 0.1.7 |
source | src |
created_at | 2024-06-07 22:07:31.684149 |
updated_at | 2024-07-15 19:23:55.599598 |
description | Krustie is a backend framework written in Rust. Currently, it is a work in progress and not yet ready for production use. |
homepage | https://github.com/emrecancorapci/krustie |
repository | https://github.com/emrecancorapci/krustie |
max_upload_size | |
id | 1265212 |
size | 66,191 |
Krustie is a backend framework written in Rust. It is currently a work in progress and not yet ready for production use. This project serves as a personal learning experience, and contributions or feedback are welcome.
use krustie::{ response::ContentType, Router, Server, StatusCode };
fn main() {
let mut server = Server::create();
let mut router = Router::new();
router.get(|_, res| {
res.status(StatusCode::Ok).body(b"Hello World!".to_vec(), ContentType::Text);
});
server.use_handler(router);
server.listen((127, 0, 0, 1), 8080);
}
As an inexperienced developer contributions will be welcomed. Please open an issue or a pull request.