diff --git a/demo.html b/demo.html index 1362fb4..5a7c41d 100644 --- a/demo.html +++ b/demo.html @@ -22,10 +22,10 @@ GitHub - + Demo - + Docs @@ -35,7 +35,7 @@
dynamicTyping
If true, numeric and boolean data will be converted to their type instead of remaining strings.preview
If > 0, only that many rows will be parsed.encoding
The encoding to use when opening files locally.worker
Whether or not to use a worker thread. Using a worker will keep your page reactive, but may be slightly slower.worker
Whether or not to use a worker thread. Using a worker will keep your page reactive, but may be slightly slower.comments
Specify a string that indicates a comment (like "#" or "//"). If your CSV file has commented lines, and Papa will skip them. This feature is disabled by default.step
To stream the input, define a callback function to receive results row-by-row rather than together at the end:
+ step
To stream the input, define a callback function to receive results row-by-row rather than together at the end:
step: function(results, handle) {
console.log("Row data:", results.data);
console.log("Row errors:", results.errors);
@@ -357,7 +357,7 @@ var csv = Papa.unparse({
error
A callback to execute if FileReader encounters an error. The function should receive two arguments: the error and the File.download
If true, this indicates that the string you passed in is actually a URL from which to download a file and parse it.keepEmptyRows
If true, rows that are empty will be included in the results as an empty array. This is useful if you want to maintain line (or at least row) parity with the original input.skipEmptyLines
If true, lines that are completely empty will be skipped. An empty line is defined to be one which evaluates to empty string.chunk
A callback, much like step, which activates streaming and is executed after every whole chunk of the file is loaded and parsed, rather than every row. Works only with local and remote files. Do not use both chunk and step callbacks together. As arguments, it receives the results, the streamer, and if parsing a local file, the File object. You can pause, resume, and abort parsing from within this function.fastMode
When enabled, fast mode executes parsing much more quickly. Only use this if you know your input won't have quoted fields.
- Yes. Parsing huge text files is facilitated by streaming, where the file is loaded a little bit at a time, parsed, and the results are sent to your step callback function, row-by-row. + Yes. Parsing huge text files is facilitated by streaming, where the file is loaded a little bit at a time, parsed, and the results are sent to your step callback function, row-by-row.
- Just specify a step callback function. Results will not be available after parsing is finished, however. You have to inspect the results one row at a time. + Just specify a step callback function. Results will not be available after parsing is finished, however. You have to inspect the results one row at a time.
- Yes, as long as you are streaming and not using a worker. Your step callback is passed a ParserHandle which has pause, resume, and abort functions. + Yes, as long as you are streaming and not using a worker. Your step callback is passed a ParserHandle which has pause, resume, and abort functions.
@@ -186,7 +186,7 @@
- Just specify worker: true
in your config. You'll also need to make a complete
callback (unless you're streaming) so that you can get the results, because using a worker makes the parse function asynchronous.
+ Just specify worker: true
in your config. You'll also need to make a complete
callback (unless you're streaming) so that you can get the results, because using a worker makes the parse function asynchronous.