rwjblue / pivot.js

Build Pivot Tables from CSV/JSON Data
http://rwjblue.github.com/pivot.js/
Other
783 stars 134 forks source link

Not processing json #28

Open indigohedgehog opened 10 years ago

indigohedgehog commented 10 years ago

At pivot.js in function init() if a json is passed, it goes to function processJSON(input) and makes a JSON.parse(input), so if a json like [[header1,...headerN],[contentA1..contentA2]..] is passed it breaks. Yet, if a [{header1:contentA1,..headerN:contentA1},{..},..] is passed it succeeds, but then it doesn't get processed on function processHeaderRow(row) because it uses rows like [h1..hn]. Function processRow(row, header, pseudoFields) has the same issue.