Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

149
Vistas
Yield a fetched file line by line in typescript

I have a huge JSONL file I need to parse.

It's really huge, so I can't download it.

I wanted to do something like this:

import { request } from "https";

request(operation.url, async (res) => {
  try {
    const rl = readline.createInterface({
      input: res,
      crlfDelay: Infinity,
    });
    for await (const line of rl) {
      yield JSON.parse(line);
    }
  } catch (error) { }
}).end();

But the callback is not a generator, so this ain't working.

Is there something else I can try?

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda