I'm currently using Papaparse(Version 5) to parse a CSV file uploaded by the user. There are no transformations being made to the file, as it is handed directly to Papaparse, who runs the following code:
Papa.parse(file, {
// we always assume line one are the headers
header: true,
skipEmptyLines: true,
complete: (data) => resolve(data),
error: error => {
reject(error.message);
},
});
When I upload the CSV (contents shown below!), and read a console.log of the result Papaparse returns, I get the following object:
In this result, we can clearly see that meta.fields includes "WorkPhone3", but, inside of data, none of the rows include the field "WorkPhone3", even though they all have values for it. This might be a bug with Papaparse. I have included in this issue the exact CSV contnets I am uploading, and posting it as text here:
I'm currently using Papaparse(Version 5) to parse a CSV file uploaded by the user. There are no transformations being made to the file, as it is handed directly to Papaparse, who runs the following code:
When I upload the CSV (contents shown below!), and read a
console.log
of the result Papaparse returns, I get the following object:In this result, we can clearly see that
meta.fields
includes"WorkPhone3"
, but, inside ofdata
, none of the rows include the field"WorkPhone3"
, even though they all have values for it. This might be a bug with Papaparse. I have included in this issue the exact CSV contnets I am uploading, and posting it as text here:CSV contents: