mafintosh / mafintosh/csv-parser
Using async function to make await call
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 1.5k
- Forks
- 143
- PR merge metrics
- No merged PRs in 30d
Description
### Feature Proposal
Using async function to make await call.
### Feature Use Case
```
const fs = require('fs');
const csv = require('csv-parser');
fs.createReadStream('file.csv')
.pipe(csv())
.on('data', async (data) => {
await myAsyncFunction(data);
})
.on('end', async () => {
await myAsyncFunctionEndOfRead();
});
```
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue provides only an example using fs.createReadStream, csv(), and async data and end handlers; it names no repository file or test. First clarify the expected behavior for awaiting those handlers, then identify the relevant entry point and define completion with a regression test.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100