From 3e4567bae8ed8ef13ed89a2f2006808142819b81 Mon Sep 17 00:00:00 2001 From: yhirose Date: Thu, 27 Aug 2020 14:16:35 -0400 Subject: [PATCH] Updated Repl.it examples --- README.md | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index b89078c..6c5a25e 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ NOTE: This is a 'blocking' HTTP library. If you are looking for a 'non-blocking' Simple examples --------------- -### [Server](https://repl.it/@yhirose/cpp-httplib-server#main.cpp): +#### Server ```c++ httplib::Server svr; @@ -24,7 +24,7 @@ svr.Get("/hi", [](const httplib::Request &, httplib::Response &res) { svr.listen("0.0.0.0", 8080); ``` -### [Client](https://repl.it/@yhirose/cpp-httplib-client#main.cpp): +#### Client ```c++ httplib::Client cli("http://cpp-httplib-server.yhirose.repl.co"); @@ -35,6 +35,11 @@ res->status; // 200 res->body; // "Hello World!" ``` +### Try out the examples on Repl.it! + +1. Run server at https://repl.it/@yhirose/cpp-httplib-server +2. Run client at https://repl.it/@yhirose/cpp-httplib-client + Server ------