I have been trying to upload a file by creating a readStream with fs.createReadStream(filePath) and piping to a writeStream. I need the file size to implement a progress bar.
In docs I see there is the readable.readableLength field, which to my understanding returns the file size but it returns zero in my case. I already got the file size with fs.statSync() but was curious.
The explanation in the documents was not really clear for me so I wanted to ask what readable.readableLength field represents? If it is the file size why it is valued zero?