@@ -29,7 +29,7 @@ $ npm install @mrodrig/json-2-csv-cli
29
29
30
30
## Upgrading?
31
31
32
- Upgrading to v4 from v3 ? Check out the [ upgrade guide] ( https://github.com/mrodrig/json-2-csv/blob/master/upgrade_guides/UPGRADE_3_to_4 .md ) .
32
+ Upgrading to v5 from v4 ? Check out the [ upgrade guide] ( https://github.com/mrodrig/json-2-csv/blob/master/upgrade_guides/UPGRADE_4_to_5 .md ) .
33
33
34
34
## Usage
35
35
@@ -45,9 +45,9 @@ Looking for examples? Check out the Wiki: [json-2-csv Wiki](https://github.com/m
45
45
46
46
### API
47
47
48
- #### ` json2csv(array, options) ` => ` Promise< string> `
48
+ #### ` json2csv(array, options) ` => ` string `
49
49
50
- Returns a ` Promise ` that resolves with the CSV ` string ` or rejects with an ` Error ` if there was an issue.
50
+ Returns the CSV ` string ` or rejects with an ` Error ` if there was an issue.
51
51
52
52
* ` array ` - An array of JSON documents to be converted to CSV.
53
53
* ` options ` - (Optional) A JSON document specifying any of the following key value pairs:
@@ -167,9 +167,9 @@ Returns a `Promise` that resolves with the CSV `string` or rejects with an `Erro
167
167
168
168
For examples, please refer to the [json2csv API Documentation (Link)](https://github.com/mrodrig/json-2-csv/wiki/json2csv-Documentation)
169
169
170
- #### `csv2json(csv, options)` => Promise< object[]>
170
+ #### `csv2json(csv, options)` => object[]
171
171
172
- Returns a `Promise` that resolves with the JSON object array (`object[]`) or rejects with an `Error` if there was an issue.
172
+ Returns the JSON object array (`object[]`) or rejects with an `Error` if there was an issue.
173
173
174
174
* `csv` - A string of CSV
175
175
* `options` - (Optional) A JSON document specifying any of the following key value pairs:
@@ -272,11 +272,11 @@ Please find the updated list (relocated to the Wiki) here: [Frequently Asked Que
272
272
* Allows for custom field delimiters, end of line delimiters, etc.
273
273
* Wrapped value support for json2csv and csv2json (as of 1.3.0)
274
274
* Support for multiple different schemas (as of 1.4.0)
275
- * Promisified versions of the functions are now available by default: json2csvAsync, csv2jsonAsync (as of 2.2.0)
276
275
* RFC 4180 Compliance (as of 3.0.0)
277
276
* CLI functionality (as of 3.0.0)
278
277
* `csv2json test.csv -o output.json`
279
278
* *and*
280
279
* `json2csv test.json -o output.csv -W -k arrayOfStrings -o output.csv`
281
280
* Empty field value option (as of 3.1.0)
282
281
* TypeScript typings included (as of 3.4.0) - thanks to [ @GabrielCastro ] ( https://github.com/GabrielCastro ) !
282
+ * Synchronous use case support (as of 5.0.0) - thanks to [ @Nokel81 ] ( https://github.com/Nokel81 )
0 commit comments