convert-csv-to-json 4.14.0 → 4.16.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/.github/workflows/ci-cd.yml +1 -1
  2. package/docs/.nojekyll +0 -0
  3. package/docs/README.md +44 -0
  4. package/docs/demo.bundle.js +1708 -0
  5. package/docs/index.html +536 -0
  6. package/eslint.config.js +1 -1
  7. package/package.json +5 -1
  8. package/docs/api/BrowserApi.html +0 -2662
  9. package/docs/api/BrowserApiError.html +0 -669
  10. package/docs/api/ConfigurationError.html +0 -745
  11. package/docs/api/CsvFormatError.html +0 -677
  12. package/docs/api/CsvParsingError.html +0 -511
  13. package/docs/api/CsvToJson.html +0 -3367
  14. package/docs/api/CsvToJsonAsync.html +0 -2880
  15. package/docs/api/FileOperationError.html +0 -382
  16. package/docs/api/FileUtils.html +0 -1150
  17. package/docs/api/InputValidationError.html +0 -407
  18. package/docs/api/JsonUtil.html +0 -452
  19. package/docs/api/JsonValidationError.html +0 -357
  20. package/docs/api/StringUtils.html +0 -833
  21. package/docs/api/global.html +0 -3498
  22. package/docs/api/index.html +0 -414
  23. package/docs/api/index.js.html +0 -447
  24. package/docs/api/scripts/app.min.js +0 -1
  25. package/docs/api/scripts/linenumber.js +0 -26
  26. package/docs/api/scripts/search.js +0 -39
  27. package/docs/api/src_browserApi.js.html +0 -362
  28. package/docs/api/src_csvToJson.js.html +0 -696
  29. package/docs/api/src_csvToJsonAsync.js.html +0 -335
  30. package/docs/api/src_util_errors.js.html +0 -472
  31. package/docs/api/src_util_fileUtils.js.html +0 -238
  32. package/docs/api/src_util_jsonUtils.js.html +0 -166
  33. package/docs/api/src_util_stringUtils.js.html +0 -306
  34. package/docs/api/styles/app.min.css +0 -1
  35. package/docs/api/styles/iframe.css +0 -13
  36. package/docs/api/styles/prettify-jsdoc.css +0 -111
  37. package/docs/api/styles/prettify-tomorrow.css +0 -132
  38. package/docs/api/styles/reset.css +0 -44
@@ -1,677 +0,0 @@
1
- <!DOCTYPE html>
2
- <html lang="en">
3
-
4
- <head>
5
-
6
- <meta charset="utf-8">
7
- <meta name="viewport" content="width=device-width, initial-scale=1">
8
- <title> CsvFormatError</title>
9
-
10
- <script src="https://cdn.jsdelivr.net/gh/google/code-prettify@master/loader/run_prettify.js"></script>
11
- <script src="https://unpkg.com/@babel/standalone/babel.min.js"></script>
12
- <script src="./build/entry.js"></script>
13
- <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
14
- <!--[if lt IE 9]>
15
- <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
16
- <![endif]-->
17
- <link href="https://fonts.googleapis.com/css?family=Roboto:100,400,700|Inconsolata,700" rel="stylesheet">
18
- <link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.6.3/css/all.css" integrity="sha384-UHRtZLI+pbxtHCWp1t77Bi1L4ZtiqrqD80Kn4Z8NTSRyMA2Fd33n5dQ8lWUE00s/" crossorigin="anonymous">
19
- <link type="text/css" rel="stylesheet" href="https://jmblog.github.io/color-themes-for-google-code-prettify/themes/tomorrow-night.min.css">
20
- <link type="text/css" rel="stylesheet" href="styles/app.min.css">
21
- <link type="text/css" rel="stylesheet" href="styles/iframe.css">
22
- <link type="text/css" rel="stylesheet" href="./node_modules/better-docs/css/better-docs.css">
23
- <script async defer src="https://buttons.github.io/buttons.js"></script>
24
-
25
-
26
- </head>
27
-
28
-
29
-
30
- <body class="layout small-header">
31
- <div id="stickyNavbarOverlay"></div>
32
-
33
-
34
- <div class="top-nav">
35
- <div class="inner">
36
- <a id="hamburger" role="button" class="navbar-burger" aria-label="menu" aria-expanded="false">
37
- <span aria-hidden="true"></span>
38
- <span aria-hidden="true"></span>
39
- <span aria-hidden="true"></span>
40
- </a>
41
- <div class="logo">
42
-
43
- <a class="image" href="index.html">
44
- <img src="https://raw.githubusercontent.com/iuccio/CSVtoJSON/master/CSVtoJSON.png" alt="logo">
45
- </a>
46
-
47
-
48
- <a href="index.html">
49
- <h1 class="navbar-item">Convert CSV to JSON</h1>
50
- </a>
51
-
52
- </div>
53
- <div class="menu">
54
-
55
- <div class="navigation">
56
- <a
57
- href="index.html"
58
- class="link"
59
- >
60
- Documentation
61
- </a>
62
-
63
-
64
-
65
- <a
66
- class="link user-link "
67
- href="https://github.com/iuccio/CSVtoJSON"
68
- >
69
- GitHub
70
- </a>
71
-
72
- <a
73
- class="link user-link "
74
- href="https://www.npmjs.com/package/convert-csv-to-json"
75
- >
76
- NPM
77
- </a>
78
-
79
-
80
-
81
- </div>
82
- </div>
83
- </div>
84
- </div>
85
- <div id="main">
86
- <div
87
- class="sidebar "
88
- id="sidebarNav"
89
- >
90
-
91
- <nav>
92
-
93
- <h2><a href="index.html">Documentation</a></h2><div class="category"></div><div class="category"><h2>1-Core API</h2><h3>Global</h3><ul><li><a href="global.html#asciiEncoding">asciiEncoding</a></li><li><a href="global.html#base64Encoding">base64Encoding</a></li><li><a href="global.html#csvStringToJson">csvStringToJson</a></li><li><a href="global.html#csvStringToJsonStringified">csvStringToJsonStringified</a></li><li><a href="global.html#csvToJsonAsync">csvToJsonAsync</a></li><li><a href="global.html#customEncoding">customEncoding</a></li><li><a href="global.html#fieldDelimiter">fieldDelimiter</a></li><li><a href="global.html#formatValueByType">formatValueByType</a></li><li><a href="global.html#generateJsonFileFromCsv">generateJsonFileFromCsv</a></li><li><a href="global.html#getJsonFromCsv">getJsonFromCsv</a></li><li><a href="global.html#hexEncoding">hexEncoding</a></li><li><a href="global.html#indexHeader">indexHeader</a></li><li><a href="global.html#latin1Encoding">latin1Encoding</a></li><li><a href="global.html#mapRows">mapRows</a></li><li><a href="global.html#parseSubArray">parseSubArray</a></li><li><a href="global.html#supportQuotedField">supportQuotedField</a></li><li><a href="global.html#trimHeaderFieldWhiteSpace">trimHeaderFieldWhiteSpace</a></li><li><a href="global.html#ucs2Encoding">ucs2Encoding</a></li><li><a href="global.html#utf16leEncoding">utf16leEncoding</a></li><li><a href="global.html#utf8Encoding">utf8Encoding</a></li></ul></div><div class="category"><h2>2-Sync</h2><h3>Classes</h3><ul><li><a href="CsvToJson.html">CsvToJson</a></li></ul></div><div class="category"><h2>3-Async</h2><h3>Classes</h3><ul><li><a href="CsvToJsonAsync.html">CsvToJsonAsync</a></li></ul></div><div class="category"><h2>4-Browser</h2><h3>Classes</h3><ul><li><a href="BrowserApi.html">BrowserApi</a></li></ul></div><div class="category"><h2>Error Classes</h2><h3>Classes</h3><ul><li><a href="BrowserApiError.html">BrowserApiError</a></li><li><a href="ConfigurationError.html">ConfigurationError</a></li><li><a href="CsvFormatError.html">CsvFormatError</a></li><li><a href="CsvParsingError.html">CsvParsingError</a></li><li><a href="FileOperationError.html">FileOperationError</a></li><li><a href="InputValidationError.html">InputValidationError</a></li><li><a href="JsonValidationError.html">JsonValidationError</a></li></ul></div><div class="category"><h2>Utilities</h2><h3>Classes</h3><ul><li><a href="FileUtils.html">FileUtils</a></li><li><a href="JsonUtil.html">JsonUtil</a></li><li><a href="StringUtils.html">StringUtils</a></li></ul></div>
94
-
95
- </nav>
96
- </div>
97
- <div class="core" id="main-content-wrapper">
98
- <div class="content">
99
- <header class="page-title">
100
- <p>Class</p>
101
- <h1>CsvFormatError</h1>
102
- </header>
103
-
104
-
105
-
106
-
107
-
108
- <section>
109
-
110
- <header>
111
-
112
- <h2><span class="attribs"><span class="type-signature"></span></span>CsvFormatError<span class="signature">(message, context)</span><span class="type-signature"></span></h2>
113
-
114
- <div class="class-description"><p>CSV parsing errors with detailed context
115
- Thrown when CSV format is invalid or malformed</p></div>
116
-
117
-
118
- </header>
119
-
120
- <article>
121
- <div class="container-overview">
122
-
123
-
124
- <div class='vertical-section'>
125
- <div class="members">
126
- <div class="member">
127
- <div class=name>
128
- <span class="tag">Constructor</span>
129
- </div>
130
-
131
-
132
-
133
-
134
- <h4 class="name" id="CsvFormatError">
135
- <a class="href-link" href="#CsvFormatError">#</a>
136
-
137
- <span class="code-name">
138
-
139
- new CsvFormatError<span class="signature">(message, context)</span><span class="type-signature"></span>
140
-
141
- </span>
142
- </h4>
143
-
144
-
145
-
146
-
147
- <div class="description">
148
- <p>Create a CSV format error</p>
149
- </div>
150
-
151
-
152
-
153
-
154
-
155
-
156
-
157
-
158
-
159
-
160
- <h5>Parameters:</h5>
161
-
162
- <div class="table-container">
163
- <table class="params table">
164
- <thead>
165
- <tr>
166
-
167
- <th>Name</th>
168
-
169
-
170
- <th>Type</th>
171
-
172
-
173
-
174
-
175
-
176
- <th class="last">Description</th>
177
- </tr>
178
- </thead>
179
-
180
- <tbody>
181
-
182
-
183
-
184
- <tr class="deep-level-0">
185
-
186
- <td class="name"><code>message</code></td>
187
-
188
-
189
- <td class="type">
190
-
191
-
192
- <code class="param-type">string</code>
193
-
194
-
195
-
196
- </td>
197
-
198
-
199
-
200
-
201
-
202
- <td class="description last"><p>Error message</p></td>
203
- </tr>
204
-
205
-
206
-
207
-
208
-
209
- <tr class="deep-level-0">
210
-
211
- <td class="name"><code>context</code></td>
212
-
213
-
214
- <td class="type">
215
-
216
-
217
- <code class="param-type">object</code>
218
-
219
-
220
-
221
- </td>
222
-
223
-
224
-
225
-
226
-
227
- <td class="description last"><p>Additional context information (optional)</p></td>
228
- </tr>
229
-
230
-
231
-
232
- </tbody>
233
- </table>
234
- </div>
235
-
236
-
237
-
238
-
239
-
240
- <dl class="details">
241
-
242
-
243
-
244
-
245
-
246
-
247
-
248
-
249
-
250
-
251
-
252
-
253
-
254
-
255
-
256
-
257
-
258
-
259
-
260
-
261
-
262
-
263
-
264
-
265
-
266
-
267
-
268
-
269
-
270
-
271
-
272
- <p class="tag-source">
273
- <a href="src_util_errors.js.html" class="button">View Source</a>
274
- <span>
275
- <a href="src_util_errors.js.html">src/util/errors.js</a>, <a href="src_util_errors.js.html#line150">line 150</a>
276
- </span>
277
- </p>
278
-
279
- </dl>
280
-
281
-
282
-
283
-
284
-
285
-
286
-
287
-
288
-
289
-
290
-
291
-
292
-
293
-
294
-
295
-
296
-
297
-
298
-
299
-
300
-
301
-
302
- </div>
303
- </div>
304
- </div>
305
-
306
-
307
- </div>
308
-
309
-
310
-
311
-
312
-
313
-
314
-
315
-
316
-
317
-
318
-
319
-
320
-
321
-
322
-
323
-
324
- <div class='vertical-section'>
325
- <h1>Methods</h1>
326
- <div class="members">
327
-
328
- <div class="member">
329
-
330
-
331
-
332
- <h4 class="name" id=".mismatchedQuotes">
333
- <a class="href-link" href="#.mismatchedQuotes">#</a>
334
-
335
-
336
- <span class='tag'>static</span>
337
-
338
-
339
- <span class="code-name">
340
-
341
- mismatchedQuotes<span class="signature">(location)</span><span class="type-signature"> &rarr; {<a href="CsvFormatError.html">CsvFormatError</a>}</span>
342
-
343
- </span>
344
- </h4>
345
-
346
-
347
-
348
-
349
- <div class="description">
350
- <p>Create error for mismatched quotes in CSV
351
- Occurs when quoted fields are not properly closed</p>
352
- </div>
353
-
354
-
355
-
356
-
357
-
358
-
359
-
360
-
361
-
362
-
363
- <h5>Parameters:</h5>
364
-
365
- <div class="table-container">
366
- <table class="params table">
367
- <thead>
368
- <tr>
369
-
370
- <th>Name</th>
371
-
372
-
373
- <th>Type</th>
374
-
375
-
376
-
377
-
378
- <th>Default</th>
379
-
380
-
381
- <th class="last">Description</th>
382
- </tr>
383
- </thead>
384
-
385
- <tbody>
386
-
387
-
388
-
389
- <tr class="deep-level-0">
390
-
391
- <td class="name"><code>location</code></td>
392
-
393
-
394
- <td class="type">
395
-
396
-
397
- <code class="param-type">string</code>
398
-
399
-
400
-
401
- </td>
402
-
403
-
404
-
405
-
406
- <td class="default">
407
-
408
- CSV
409
-
410
- </td>
411
-
412
-
413
- <td class="description last"><p>Where the error occurred (default: 'CSV')</p></td>
414
- </tr>
415
-
416
-
417
-
418
- </tbody>
419
- </table>
420
- </div>
421
-
422
-
423
-
424
-
425
-
426
- <dl class="details">
427
-
428
-
429
-
430
-
431
-
432
-
433
-
434
-
435
-
436
-
437
-
438
-
439
-
440
-
441
-
442
-
443
-
444
-
445
-
446
-
447
-
448
-
449
-
450
-
451
-
452
-
453
-
454
-
455
-
456
-
457
-
458
- <p class="tag-source">
459
- <a href="src_util_errors.js.html" class="button">View Source</a>
460
- <span>
461
- <a href="src_util_errors.js.html">src/util/errors.js</a>, <a href="src_util_errors.js.html#line186">line 186</a>
462
- </span>
463
- </p>
464
-
465
- </dl>
466
-
467
-
468
-
469
-
470
-
471
-
472
-
473
-
474
-
475
-
476
-
477
-
478
-
479
-
480
-
481
-
482
-
483
-
484
- <div class='columns method-parameter'>
485
- <div class="column is-2"><label>Returns:</label></div>
486
- <div class="column is-10">
487
-
488
-
489
-
490
- <div class="columns">
491
-
492
- <div class='param-desc column is-7'><p>Configured error instance</p></div>
493
-
494
-
495
- <div class='column is-5 has-text-left'>
496
- <label>Type: </label>
497
-
498
- <code class="param-type"><a href="CsvFormatError.html">CsvFormatError</a></code>
499
-
500
-
501
- </div>
502
-
503
- </div>
504
-
505
-
506
- </div>
507
- </div>
508
-
509
-
510
-
511
-
512
- </div>
513
-
514
- <div class="member">
515
-
516
-
517
-
518
- <h4 class="name" id=".missingHeader">
519
- <a class="href-link" href="#.missingHeader">#</a>
520
-
521
-
522
- <span class='tag'>static</span>
523
-
524
-
525
- <span class="code-name">
526
-
527
- missingHeader<span class="signature">()</span><span class="type-signature"> &rarr; {<a href="CsvFormatError.html">CsvFormatError</a>}</span>
528
-
529
- </span>
530
- </h4>
531
-
532
-
533
-
534
-
535
- <div class="description">
536
- <p>Create error for missing CSV header row
537
- Occurs when no valid header row is found in CSV</p>
538
- </div>
539
-
540
-
541
-
542
-
543
-
544
-
545
-
546
-
547
-
548
-
549
-
550
-
551
-
552
-
553
- <dl class="details">
554
-
555
-
556
-
557
-
558
-
559
-
560
-
561
-
562
-
563
-
564
-
565
-
566
-
567
-
568
-
569
-
570
-
571
-
572
-
573
-
574
-
575
-
576
-
577
-
578
-
579
-
580
-
581
-
582
-
583
-
584
-
585
- <p class="tag-source">
586
- <a href="src_util_errors.js.html" class="button">View Source</a>
587
- <span>
588
- <a href="src_util_errors.js.html">src/util/errors.js</a>, <a href="src_util_errors.js.html#line167">line 167</a>
589
- </span>
590
- </p>
591
-
592
- </dl>
593
-
594
-
595
-
596
-
597
-
598
-
599
-
600
-
601
-
602
-
603
-
604
-
605
-
606
-
607
-
608
-
609
-
610
-
611
- <div class='columns method-parameter'>
612
- <div class="column is-2"><label>Returns:</label></div>
613
- <div class="column is-10">
614
-
615
-
616
-
617
- <div class="columns">
618
-
619
- <div class='param-desc column is-7'><p>Configured error instance</p></div>
620
-
621
-
622
- <div class='column is-5 has-text-left'>
623
- <label>Type: </label>
624
-
625
- <code class="param-type"><a href="CsvFormatError.html">CsvFormatError</a></code>
626
-
627
-
628
- </div>
629
-
630
- </div>
631
-
632
-
633
- </div>
634
- </div>
635
-
636
-
637
-
638
-
639
- </div>
640
-
641
- </div>
642
- </div>
643
-
644
-
645
-
646
-
647
-
648
- </article>
649
-
650
- </section>
651
-
652
-
653
-
654
-
655
- </div>
656
-
657
- <footer class="footer">
658
- <div class="content has-text-centered">
659
- <p>Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.5</a></p>
660
- <p class="sidebar-created-by">
661
- <a href="https://github.com/SoftwareBrothers/better-docs" target="_blank">BetterDocs theme</a> provided with <i class="fas fa-heart"></i> by
662
- <a href="http://softwarebrothers.co" target="_blank">SoftwareBrothers - JavaScript Development Agency</a>
663
- </p>
664
- </div>
665
- </footer>
666
-
667
- </div>
668
- <div id="side-nav" class="side-nav">
669
- </div>
670
- </div>
671
- <script src="scripts/app.min.js"></script>
672
- <script>PR.prettyPrint();</script>
673
- <script src="scripts/linenumber.js"> </script>
674
-
675
-
676
- </body>
677
- </html>