Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

json2csv

Package Overview
Dependencies
Maintainers
4
Versions
104
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

json2csv - npm Package Compare versions

Comparing version 5.0.1 to 5.0.2

6

bin/json2csv.js

@@ -17,4 +17,2 @@ #!/usr/bin/env node

const writeFile = promisify(writeFileOrig);
const isAbsolutePath = promisify(isAbsolute);
const joinPath = promisify(join);

@@ -52,4 +50,4 @@ const { unwind, flatten } = json2csv.transforms;

function makePathAbsolute(filePath) {
return (filePath && !isAbsolutePath(filePath))
? joinPath(process.cwd(), filePath)
return (filePath && !isAbsolute(filePath))
? join(process.cwd(), filePath)
: filePath;

@@ -56,0 +54,0 @@ }

@@ -5,2 +5,9 @@ # Changelog

### [5.0.2](https://github.com/zemirco/json2csv/compare/v5.0.1...v5.0.2) (2020-09-24)
### Bug Fixes
* **cli:** fix relative paths issue in CLI when not streaming ([#488](https://github.com/zemirco/json2csv/issues/488)) ([06079e8](https://github.com/zemirco/json2csv/commit/06079e840128030eacfecde66da11295eb162234))
### [5.0.1](https://github.com/zemirco/json2csv/compare/v5.0.0...v5.0.1) (2020-04-28)

@@ -491,3 +498,3 @@

* Preserve new lines in cells with option preserveNewLinesInCells ([#91](https://github.com/zemirco/json2csv/issues/91)) ([#171](https://github.com/zemirco/json2csv/issues/171)) ([187b701](https://github.com/zemirco/json2csv/commit/187b701))
* Preserve new lines in cells with option `preserveNewLinesInValues` ([#91](https://github.com/zemirco/json2csv/issues/91)) ([#171](https://github.com/zemirco/json2csv/issues/171)) ([187b701](https://github.com/zemirco/json2csv/commit/187b701))

@@ -494,0 +501,0 @@

{
"name": "json2csv",
"version": "5.0.1",
"version": "5.0.2",
"description": "Convert JSON to CSV",

@@ -62,3 +62,3 @@ "keywords": [

"rollup-plugin-node-resolve": "^5.2.0",
"standard-version": "^7.0.0",
"standard-version": "^8.0.1",
"tap-spec": "^5.0.0",

@@ -65,0 +65,0 @@ "tape": "^4.10.1"

@@ -9,3 +9,2 @@ # json2csv

[![Coverage Status][coveralls-badge]][coveralls-badge-url]
[![Dependency Status][dev-badge]][dev-badge-url]

@@ -191,3 +190,3 @@ See the [CHANGELOG] for details about the latest release.

`json2csv` can also be use programatically as a synchronous converter using its `parse` method.
`json2csv` can also be used programatically as a synchronous converter using its `parse` method.
```js

@@ -881,3 +880,3 @@ const { Parser } = require('json2csv');

```js
const { Parser, transform: { unwind, flatten } } = require('json2csv');
const { Parser, transforms: { unwind, flatten } } = require('json2csv');
const json2csvParser = new Parser({ transforms: [unwind({ paths, blankOut: true }), flatten('__')] });

@@ -973,5 +972,3 @@ const csv = json2csvParser.parse(myData);

[coveralls-badge-url]: https://coveralls.io/r/zemirco/json2csv?branch=master
[dev-badge]: https://david-dm.org/zemirco/json2csv.svg
[dev-badge-url]: https://david-dm.org/zemirco/json2csv
[CHANGELOG]: https://github.com/zemirco/json2csv/blob/master/CHANGELOG.md
[LICENSE.md]: https://github.com/zemirco/json2csv/blob/master/LICENSE.md
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc