Created
February 5, 2020 07:44
-
-
Save ArturJS/47bb9e87a270d6dfeecbbbef315d87a7 to your computer and use it in GitHub Desktop.
Deno server
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { serve } from "https://deno.land/std@v0.30.0/http/server.ts"; | |
const s = serve({ port: 8000 }); | |
console.log("http://localhost:8000/"); | |
for await (const req of s) { | |
req.respond({ body: "Hello World\n" }); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment