lazy.js icon indicating copy to clipboard operation
lazy.js copied to clipboard

Implement lazy JSON parsing

Open dtao opened this issue 11 years ago • 6 comments

I'm pretty sure this is possible, and I'm totally going to do it.

Alternately, if somebody else wants to implement it, I would gladly give you push access.

dtao avatar Jun 24 '13 14:06 dtao

Can't wait! Does it parse json stream like yajl?

hden avatar Jun 27 '13 13:06 hden

That's the idea!

That said, it will take a while for me to implement this. It would be naive of me to think I could just bang out a JSON parser in a few days, having next to zero experience doing anything like that. However, I do think Lazy.js provides exactly the right framework for doing this (parsing a JSON array as a Lazy.Sequence, or an object as a Lazy.ObjectLikeSequence) and so it is a definite "will-do" as opposed to a "might-do" :)

dtao avatar Jun 27 '13 14:06 dtao

Any update on this, or anything I can help with?

hden avatar Sep 04 '13 09:09 hden

@hden: No updates, sadly. I choose to blame this on my new baby daughter, who was just born a few weeks ago. If you want to take a crack at it, be my guest! However, I am about to do a bit of work on Lazy right now; so who knows—maybe I'll make a little progress on this very issue. Rest assured I will update this ticket if/when there's any more to report.

dtao avatar Sep 19 '13 00:09 dtao

Well, it's still a work in progress and only works with JSON arrays, but a proof-of-concept demo is now available:

http://danieltao.com/lazy.js/experimental/

dtao avatar Nov 08 '13 21:11 dtao

Hi @dtao Is this implemented? Can I work on it?

AkshayIyer12 avatar Dec 10 '17 05:12 AkshayIyer12