FaberVitale / deno-ndjson

Read, write, parse and serialize new line delimited JSON in deno: http://ndjson.org/
MIT License
3 stars 0 forks source link

std/io/buffer is deprected - plans to switch to std//streams/buffer.ts #2

Open indus opened 10 months ago

indus commented 10 months ago

I'm currently using your lib like so:

import { Buffer } from "https://deno.land/std/io/buffer.ts";
...

let file = new Buffer(buf);
for await (const feat of parseNdjson(file)) {
...

But from what I get the whole Reader/Writer Stuff is deprecated (https://github.com/denoland/deno_std/issues/1986)

Do you have any plans to rewrite your lib to streams?

FaberVitale commented 10 months ago

It seems that streams/Buffer is not a Deno.Reader.

I'm leaning toward adding a new overload to support this new Buffer class.

I'll work on an implementation asap.