Browse Source

Updated docs to be more succint and add versioning

pull/898/head
theLAZYmd 4 years ago
parent
commit
ac6f19168c
  1. 7
      docs/docs.html

7
docs/docs.html

@ -510,12 +510,16 @@ var csv = Papa.unparse({
<code>transformHeader</code> <code>transformHeader</code>
</td> </td>
<td> <td>
A function to apply on each header. Requires <code>header</code> to be <code>true</code>. The function receives the header as its first argument and the index (the column number) as second. When used in conjunction with config.headerLines, the function receives a third and fourth parameter which are: A function to apply on each header. Requires <code>header</code> to be <code>true</code>. The arguments are:
<ul> <ul>
<li><b>header:</b> the current header text, as parsed from the appropriate cell in the specified header row</li>
<li><b>index:</b> the column number of the header text (0 for first column)</li>
<li><b>arr:</b> the string array of data for that row</li> <li><b>arr:</b> the string array of data for that row</li>
<li><b>acc:</b> the existing header for that column based on previous lines iteration ('' if no previous lines)</li> <li><b>acc:</b> the existing header for that column based on previous lines iteration ('' if no previous lines)</li>
<li><b>j:</b> the rowNumber (0 for the first line)</li> <li><b>j:</b> the rowNumber (0 for the first line)</li>
</ul> </ul>
Only available starting with version 5.0.
The latter three parameters (arr, acc, j) are only available when used in conjunction with config.headerLines and from version 5.4+.
</td> </td>
</tr> </tr>
<tr> <tr>
@ -524,6 +528,7 @@ var csv = Papa.unparse({
</td> </td>
<td> <td>
The number of rows which will be used to transform into a header, and removed from the rest of the data. Requires header to be true. Default 1. The number of rows which will be used to transform into a header, and removed from the rest of the data. Requires header to be true. Default 1.
Only available starting with veresion 5.4.
</td> </td>
</tr> </tr>
<tr> <tr>

Loading…
Cancel
Save