Skip to content
forked from mattn/clask

Web micro-framework like flask in C++.

Notifications You must be signed in to change notification settings

Ryooooooga/clask

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

clask

C/C++ CI

Very Very Experimental Web micro-framework like flask in C++.

DO NOT USE THIS IN PRODUCTION

Usage

#include "clask/core.hpp"

int main() {
  auto s = clask::server();
  s.GET("/", [](clask::request& req) {
    return "OK!";
  });
  s.GET("/foo", [](clask::response& resp, clask::request& req) {
    resp.set_header("content-type", "text/html");
    resp.write("he<b>l</b>lo");
  });
  s.run();
}

TODO

  • Unescape paths in request
  • Unescape query parameters in request
  • Implement keep-alive
  • Serve static file
  • Responses oriented classes such as JSON

License

MIT

This product contains following third-party libraries:

  • picohttpparser written by kazuho

Author

Yasuhiro Matsumoto (a.k.a. mattn)

About

Web micro-framework like flask in C++.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 78.5%
  • HTML 19.3%
  • Other 2.2%