Comment

Comment by zebracanevra

fetch's Response.text also returns a Promise, so you'd have to await twice:

  const lines = (await (await fetch(myUrl)).text()).split('\n');

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton