Skip to content

Releases: coston/json-to-csv-export

v3.1.0

02 Oct 14:18
8cd6ca0
Compare
Choose a tag to compare

3.1.0 (2024-10-02)

Features

v3.0.1

09 Aug 18:58
8d966d1
Compare
Choose a tag to compare

3.0.1 (2024-08-09)

Bug Fixes

RFC-4180 Compliance

31 Jul 00:20
Compare
Choose a tag to compare

Breaking Change

  • Default Delimiter Change: The default delimiter has been switched from semicolon (;) to comma (,), in compliance with RFC-4180. This change may affect users relying on the previous default delimiter. Please update your configurations accordingly. For more details, see the discussion here.

New Features and Improvements

  • RFC-4180 Compliance: The library now adheres to RFC-4180 rules, ensuring that cell values are wrapped in double-quotes only when they contain a quote, comma (or semicolon if using a semicolon as the delimiter), or carriage-return/newline. This improvement reduces the total file size by avoiding unnecessary quote wrapping and adds stability to generated files, preventing issues with values containing delimiters or newline characters, which are valid for CSV but could previously cause output errors.

Other Updates

  • Testing Enhancements: Additional tests have been added to ensure that the generated Blob used in CSV downloads is correctly formatted.

Acknowledgments

Thank you @zachelrath for delivering RFC-4180 compliance ⭐

Updates

  • feat(#61)!: Change default delimiter to comma (#64) d1221b8
  • chore(deps): Bump postcss and next (#54) 7c6a93f
  • chore(deps-dev): Bump @babel/traverse from 7.20.12 to 7.23.2 (#56) 08c5449
  • chore: Increase Node compatibility ec243d8
  • chore: Increase Node version compatibility eca2d64

For a full list of changes, see the compare view.

cjs and esm exports

07 Aug 18:53
Compare
Choose a tag to compare
cjs and esm exports Pre-release
Pre-release

v2.1.1...v2.2.0-0

v2.1.1

05 Dec 22:16
Compare
Choose a tag to compare
  • chore: assorted formatting 6deba42
  • fix(#42): properly escape double-quotes in string fields 06fc2a4
  • chore(deps): bump loader-utils from 1.4.0 to 1.4.2 (#41) c61e3fc

v2.1.0...v2.1.1

feat: BOM support for special characters in Excel

28 Oct 22:14
Compare
Choose a tag to compare
  • feat(#38): BOM support for special characters in Excel (#39) 1a1c6ba

v2.0.2...v2.1.0

Output esm and cjs

14 Sep 13:20
Compare
Choose a tag to compare
v2.0.2

2.0.2

Output esm and cjs

14 Sep 13:16
Compare
Choose a tag to compare
Output esm and cjs Pre-release
Pre-release
  • chore: output esm and cjs e07e472

v2.0.1...v2.0.2-0

fix: build to TS commonjs

14 Sep 12:34
Compare
Choose a tag to compare

Named parameters and Typescript

13 Sep 22:44
Compare
Choose a tag to compare

Description

Thanks to @dnim for updating the lib to TS and refactoring the function to take named parameters for a simpler developer experience when working when specifying customized behavior.

Breaking Changes

  • Named parameters are now required for passing custom data, filename, and delimeter props.
  • Support for the IE navigator.msSaveBlob method was removed from the code (as it was removed in new versions of TypeScript).
  • File name can be provided without .csv extension, it will be added automatically

Migration Steps

  • update to the new version (2.x)
  • map arguments on object props. I.e:
const props = {
  data: data,
  filename: filename,
  delimiter: delimiter
}
csvDownload(props);

Full list of changes:

  • chore: bump version e163536
  • chore: update lockfile and format code c79d692
  • refactor!: update the lib to TS and require named parameters (#30) 4e1a392
  • chore(deps): bump ajv from 6.5.4 to 6.12.6 (#33) 62f99a8
  • chore(deps): bump chownr and chownr (#32) 35e8419

v1.1.2...v2.0.0