feat: initial development

This commit is contained in:
2023-07-27 01:47:59 +04:00
commit 85dc5981cd
30 changed files with 3075 additions and 0 deletions

15
Demo/Program.cs Normal file
View File

@@ -0,0 +1,15 @@
using NaiveHttpServer;
var server = new Server("localhost", 2333);
server
.Use(Middlewares.Log)
.Use(Middlewares.ExceptionHandling)
.Use(Middlewares.StaticFile("/files", Environment.CurrentDirectory))
.Use(Middlewares.NotFound(documentUrl: "http://api.project.com/v1"));
server.Start();
Console.ReadKey();
server.Stop();