krustie

Crates.iokrustie
lib.rskrustie
version0.2.0
sourcesrc
created_at2024-06-07 22:07:31.684149
updated_at2024-10-13 21:36:32.067084
descriptionKrustie is a simple and easy-to-use backend framework.
homepagehttps://github.com/emrecancorapci/krustie
repositoryhttps://github.com/emrecancorapci/krustie
max_upload_size
id1265212
size112,035
Emre Can Çorapçı (emrecancorapci)

documentation

README

Krustie - A Basic Backend Framework

github crates.io docs.rs build status

Krustie is a simple backend framework. It is designed to be a easy-to-use HTTP web server that can be used for a variety of purposes. Krustie's error-proof design aims to make it harder to write bugs.

Krustie is still in the early stages of development and is not yet ready for production use. The API is subject to change and there may be bugs or missing features.

Features

  • Router with support for parameter and query string parsing
  • Middleware support for routers and endpoints
  • Minimal testing support
  • JSON data parsing and serialization (using the serde library)

Built-in Middlewares

  • Static file serving
  • Rate limiting
  • Gzip compression

Start your server

use krustie::{ Router, Server, StatusCode };

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

    router.get("/", |_, res| {
        res.status(StatusCode::Ok).body_text("Hello World!");
    });

    server.use_handler(router);

    server.listen(8080);
}

Contributing

All contributions are welcomed. Please open an issue or a pull request to report a bug or request a feature.

Commit count: 189

cargo fmt