Comment

Comment by apitman

  BunnySDK.net.http.serve(async (request: Request): Response | Promise<Response> => {
    return new Response("Hello World");
  });
I love that pretty much all the JS runtimes have settled on `(Request): Response`[0], but I really wish they would standardize starting the server as well. Would make writing cross-runtime services easier.

[0]: https://blog.val.town/blog/the-api-we-forgot-to-name/

parent apitman 2 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton