Explorar o código

Update README.md

Added a snippet for Scopes DSL.
Damian Kołakowski %!s(int64=10) %!d(string=hai) anos
pai
achega
cd9fec33ac
Modificáronse 1 ficheiros con 12 adicións e 0 borrados
  1. 12 0
      README.md

+ 12 - 0
README.md

@@ -32,6 +32,18 @@ server["/redirect"] = { request in
 }
 server.start()
 ```
+### How to HTML ?
+```swift
+let server = HttpServer()
+server["/my_html"] = HttpHandlers.scopes { 
+  html {
+    body {
+      h1 { inner = "hello" }
+    }
+  }
+}
+server.start()
+```
 ### CocoaPods? Yes.
 ```
 use_frameworks!