github-profile-trophy-reiyu.../dev_main.ts
2020-08-23 19:08:08 +09:00

11 lines
302 B
TypeScript

import { serve } from "https://deno.land/std@0.66.0/http/server.ts";
import { Card } from "./src/card.ts";
const s = serve({ port: 8080 });
for await (const req of s) {
req.respond(
{
body: new Card().render(),
headers: new Headers({ "Content-Type": "image/svg+xml" }),
},
);
}