Answer the question
In order to leave comments, you need to log in
How to fix file read error in createReadStream method of FS module?
Good day!
A few minutes ago, I encountered an error that was made after I integrated the FS module with a library for reading CSV files :
TypeError: Cannot read properties of undefined (reading 'createReadStream')
9 | const CsvReadableStream = require('csv-reader');
10 |
11 |
> 12 | let inputDataset = [
13 | Fsp.createReadStream('../datasets/productCategories.csv', 'utf8').pipe(new CsvReadableStream({ parseNumbers: true, parseStrings: true, trim: true }))
14 | ];
15 |
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question