diff --git a/data/sample.ts b/data/sample.ts new file mode 100644 index 0000000..e860653 --- /dev/null +++ b/data/sample.ts @@ -0,0 +1,10 @@ +import { serve } from 'https://deno.land/std@0.77.0/http/server.ts'; + +const PORT = 1993; +const s = serve(`0.0.0.0:${PORT}`); +const body = new TextEncoder().encode('Hello World\n'); + +console.log(`Server started on port ${PORT}`); +for await (const req of s) { + req.respond({ body }); +}