Closed or1can closed 6 years ago
Hi. Thanks for the error-report. Are you using ngx-papaparse 2.x or 3.x?
I'm using 3.0.0-beta.0
Thanks. I'll take a look at it. :-)
I have changed the interface to:
complete?: (results: PapaParseResult, file?: File) => void;
.
The change will be included in the next release.
Describe the bug
The complete callback has the following signature is PapaParseConfig
complete?: (results: PapaParseResult, parser: PapaParseParser) => void;
but Papa Parse actually calls with the results and a File object if parsing a local file.
This causes type errors when using this callback and the only workaround I found was to define a complete callback specifying the type of the second argument as
any
, e.g.complete: (results, file: any) => {}
The signature for
step
looks correct, I'm not sure aboutchunk
.