saghul / txiki.js

A tiny JavaScript runtime
MIT License
2.47k stars 165 forks source link

Response implementation does not meet expectations #646

Open 2234839 opened 3 weeks ago

2234839 commented 3 weeks ago
  const r= await new Response("500", {
    status: 500,
    headers: {
      "Content-Type": "text/plain",
    },
  }).body;
  console.log("[r]", r); 

This is supposed to be ReadableStream, but now it's undefined

saghul commented 3 weeks ago

Yep, this is known as the current fetch polyfill in use if not great. I'm working oon replacing it with something better.