Closed jacquarg closed 9 years ago
I am kinda afraid to merge that. Have you made more manual testing? Does it solve your bug on you bigger file?
I agree with your feeling ! I did some manual tests (sadly, it didn't work on first tests : ), but now it works with my big files and solves the bug.
The integration of the new line parser were effortlessly, and is ugly. I will take a look if it can be cleaned.
@frankrousseau since you have written the first version of the parser, can you have a look at the code too?
If you want to change it, I think we should make it fully based on stream. Here is a nice lib that will help you to achieve that: https://www.npmjs.com/package/byline
You can make the parser inherit from:
http://nodejs.org/api/stream.html#stream_class_stream_readable
And use standard functions like pause
.
Ok, I will look at it. There is indeed no need to reinvent the wheel, as there isn't preemption in nodejs.
It's not about reinventing the wheel, it's about matching the usual Node API. Currently, you named a class as a ReadStream
, so it should match the Node API. And I prefer to make things the Node way instead of renaming the class.
Add standard but non-normative X-WR-CALNAME field support to export and import calendar name. Change readline algorithme for file parse. Use a custom line by line in order stream reader, instead of lazy.