aboutsummaryrefslogblamecommitdiffstats
path: root/example.cpp
blob: c518dc47890271c7d290af8e20efe70043c7c3ee (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11

                  

                   

          




                     


                              

                       


                                      




                                        

                  
 
#include "flask.h"

#include <iostream>

int main()
{
    flask::Flask app;

    app.route("/")
       .name("hello")
    ([]{
        return "Hello World!";
    });

    app.route("/about")
    ([]{
        return "About Flask example.";
    });

    //app.route("/hello/<int>");
    //([]{
        //return "About Flask example.";
    //});

    app.port(8080)
       .run();
}