node-csv
node-csv copied to clipboard
Assign row number to each record
Summary
The idea is to opt into adding a row number and having that value assigned to a configured property.
Motivation
It's handy for me because it allows my user interface to tell the user where that data has come from better.
Alternative
I have considered adding a row number to my CSV raw data before putting it in csv-parse.
Draft
parse({
row: true, // will result in a row property added to each record
row: 'some_other_field' // will assign the row number to that field.
})
Column number is also handy
-- https://delta.chat
I see there is a on_record option. It has lines let me check if it has columns too...