Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(#61)!: Change default delimiter to semicolon #64

Merged
merged 1 commit into from
Jul 31, 2024

Conversation

zachelrath
Copy link
Contributor

@zachelrath zachelrath commented Jul 30, 2024

Breaking change

  • Switches the default delimiter from semicolon to comma, to comply with RFC-4180. See discussion in Use comma as default separator to comply with RFC-4180 #61
  • Implements RFC-4180 rules for ensuring that cell values are only wrapped in double-quotes when the value contains a quote, comma (or semicolon if using semicolon as delimiter), or carriage-return/newline. This minimizes the total file size by avoiding unnecessary quote wrapping, while adding additional stability to generated files whose values contain the delimiter or newline characters, which are valid for CSV but would currently break the output in 2.x.
  • Adds additional tests to validate that the generated Blob used in CSV downloads is correctly formatted.

closes #61

Copy link

vercel bot commented Jul 30, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
json-to-csv-export ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 30, 2024 0:44am

@zachelrath zachelrath force-pushed the use-comma-as-default-separator branch from 80b7212 to aa2a653 Compare July 30, 2024 12:43
@coston coston changed the title feat: Change default delimiter to semicolon feat(#61)!: Change default delimiter to semicolon Jul 30, 2024
Copy link
Owner

@coston coston left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent updates, @zachelrath!

@coston coston merged commit d1221b8 into coston:master Jul 31, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Use comma as default separator to comply with RFC-4180
2 participants