json-2-csv
Advanced tools
Comparing version 5.3.0 to 5.4.0
@@ -17,2 +17,3 @@ 'use strict'; | ||
exports.defaultJson2CsvOptions = { | ||
arrayIndexesAsKeys: false, | ||
checkSchemaDifferences: false, | ||
@@ -19,0 +20,0 @@ delimiter: { |
@@ -33,2 +33,3 @@ 'use strict'; | ||
const wrapDelimiterCheckRegex = new RegExp(options.delimiter.wrap, 'g'), crlfSearchRegex = /\r?\n|\r/, customValueParser = options.parseValue && typeof options.parseValue === 'function' ? options.parseValue : null, expandingWithoutUnwinding = options.expandArrayObjects && !options.unwindArrays, deeksOptions = { | ||
arrayIndexesAsKeys: options.arrayIndexesAsKeys, | ||
expandNestedObjects: options.expandNestedObjects, | ||
@@ -35,0 +36,0 @@ expandArrayObjects: expandingWithoutUnwinding, |
@@ -76,2 +76,6 @@ interface DelimiterOptions { | ||
export interface Json2CsvOptions extends SharedConverterOptions { | ||
/** Should array indexes be included in the generated keys? | ||
* @default false | ||
*/ | ||
arrayIndexesAsKeys?: boolean; | ||
/** | ||
@@ -78,0 +82,0 @@ * Should all documents have the same schema? |
@@ -8,3 +8,3 @@ { | ||
"description": "A JSON to CSV and CSV to JSON converter that natively supports sub-documents and auto-generates the CSV heading.", | ||
"version": "5.3.0", | ||
"version": "5.4.0", | ||
"homepage": "https://mrodrig.github.io/json-2-csv", | ||
@@ -43,4 +43,4 @@ "repository": { | ||
"dependencies": { | ||
"deeks": "3.0.2", | ||
"doc-path": "4.0.2" | ||
"deeks": "3.1.0", | ||
"doc-path": "4.1.0" | ||
}, | ||
@@ -47,0 +47,0 @@ "devDependencies": { |
@@ -53,2 +53,5 @@ # json-2-csv | ||
* `options` - (Optional) A JSON document specifying any of the following key value pairs: | ||
* `arrayIndexesAsKeys` - Boolean - Should array indexes be included in the generated keys? | ||
* Default: `false` | ||
* Note: This provides a more accurate representation of the JSON in the returned CSV, but may be less human readable. See [#207](https://github.com/mrodrig/json-2-csv/issues/207) for more details. | ||
* `checkSchemaDifferences` - Boolean - Should all documents have the same schema? | ||
@@ -55,0 +58,0 @@ * Default: `false` |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
104548
1365
308
+ Addeddeeks@3.1.0(transitive)
+ Addeddoc-path@4.1.0(transitive)
- Removeddeeks@3.0.2(transitive)
- Removeddoc-path@4.0.2(transitive)
Updateddeeks@3.1.0
Updateddoc-path@4.1.0