Questions tagged [papaparse]

Papa Parse is a fast and powerful CSV parser for JavaScript.

Papa Parse (formerly the jQuery Parse Plugin) is a robust and powerful CSV (character-separated values) parser with these features:

  • Easy to use
  • Parse CSV files directly (local or over the network)
  • Stream large files (even via HTTP)
  • Reverse parsing (converts JSON to CSV)
  • Auto-detect the delimiter
  • Worker threads to keep your web page reactive
  • Header row support
  • Pause, resume, abort
  • Can convert numbers and booleans to their types
  • Graceful and robust error handling
  • Minor jQuery integration to get files from <input type="file"> elements
  • Papa Parse has no dependencies - not even jQuery.

Visit the Papa Parse project page on GitHub.

Homepage & Demo

To learn how to use Papa Parse: see Documentation.

papaparse.min.js can be linked or downloaded to your project source.

418 questions
-1
votes
1 answer

How can I get German umlauts with fs.readFileSync?

I want to try to read my csv file and convert it so that I have the german umlauts back in. How can I convert this? my code: export const convertCSV = (req: Request, res: Response) => { const file = fs.readFileSync(path.resolve(__dirname, '..',…
redlightfilms
  • 193
  • 1
  • 4
  • 13
-1
votes
1 answer

Returning the result after reading the csv file

I am using PapaParse to read remote csv file and return the result, but every time it's empty not sure why. function importData(url){ const parseStream = Papa.parse(Papa.NODE_STREAM_INPUT, {}); let length = 0; const…
Peril
  • 1,569
  • 6
  • 25
  • 42
-1
votes
1 answer

Papaparse, ReferenceError: variable is not defined

I'm working on a Geocharts map that imports some data with PapaParse. The issue I'm having is a ReferenceError on line temp = CovidData.data.find(element[1] === countries[c]);. I'm using the PapaParse library to parse a csv file I grabbed off of…
tanto
  • 339
  • 1
  • 2
  • 11
-1
votes
1 answer

Data is displayed strange when parsed with papaparse

I am trying to display csv data in highcharts via an input, for this i need papaparse. My Data looks like this: Tasks,Run,Count task1,4.96,150 task2,156.166666666667,150 task3,279.369565217391,92 task4,1718,16 task5,2.375,16 Therefore, the graph…
J.Doe
  • 586
  • 2
  • 8
  • 30
-1
votes
1 answer

Javascript parsing json object

As you can see based on the columns from the excel one column has "space" which is the Categorized Options that when being parsed the 'Categorized Options': was mixed to the Options key as you can see on the json data below. Categorized Options is…
user11327631
-1
votes
1 answer

Uncaught ReferenceError: Papa is not defined. Loaded in from cdn in header

Below is the HTML. I load in the cdn hosted lib for PapaParse in the header. But when I run my JavaScript file and it runs the function where I call Papa.unparse(data); It throws an error saying that Papa is not defined. So I am a bit confused on…
MattyP
  • 25
  • 11
-1
votes
1 answer

papa.unparse creates empty csv files

function savecsv(){ var obj = {}; $("input").each(function(){ obj[this.id]=this.value;}); console.log(obj); var csv = Papa.unparse(obj); return csv; } Hey i have some, prolly simple problems using papa.unparse, it creates…
-1
votes
1 answer

How to parse only first 2 rows of csv with javascript

I am trying to only get first 2 rows of csv and I have no idea how to do it.This gets whole csv data. Here is my code,