Fixing a conversion bug and adding ability to output json #1
No reviewers
Labels
No Label
DBF
Dates
Defined Names
Features
Formula
HTML
Images
Infrastructure
Integration
International
ODS
Operations
Performance
PivotTables
Pro
Protection
Read Bug
SSF
SYLK
Style
Write Bug
good first issue
No Milestone
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: sheetjs/sheetjs#1
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "master"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Here's a link where you can see the changes in action.
I like the general idea of JSON output, but here are a few things to mull over (I'm not saying these are wrong, but JSON forces a certain type of structure which doesn't fit all XLSX sheets):
yields
BTW: It's not wrong to require the structure you are assuming here
sheets with numbers throw an error (but that's a minor fix)
In the aforementioned example, gaps in the sheet are not retained (there are two empty rows, but the JSON output doesn't reflect that). Again, it's not wrong to explicitly require that the data is contiguous
I guess these lead to the general question: What are the advantages of having the script do the work rather than using a CSV to JSON converter (aside from additional work and additional dependencies)?
sheet_to_row_object_array is just a convenience function, but it's a really nice one to have. I don't know of a better format for dealing with tabular data in Javascript. For example, I can use underscore collection functions to essentially query my tables (e.g.
).
W.r.t. 2: It would be nice to preserve the type of numbers, bools and datetimes from excel, however strings are sufficient for the project I'm working on right now.
Pull request closed