[][src]Crate sincere

Sincere is a micro web framework for Rust(stable) based on hyper and multithreadind. Style like koa. The same, which aims to be a smaller, more expressive, and more robust foundation for web applications and APIs. Sincere does not bundle any middleware within core, and provides an elegant suite of methods that make writing servers fast and enjoyable.

Usage

First, add this to your Cargo.toml:

[dependencies]
sincere = "0.5.8"

Then, add this to your crate root:

extern crate sincere;

Example

use sincere::App;

fn main() {
   let mut app = App::new();

   app.get("/", |context| {
       context.response.from_text("Hello world!").unwrap();
   });

   //app.run("127.0.0.1:8000", 20).unwrap();
}

Re-exports

pub extern crate nson;
pub use self::app::App;
pub use self::error::Error;

Modules

app

App container.

error
http
log
text
util

Macros

middleware
route