Methods
(static) getReadStream(filePath) → {ReadableStream}
Opens a readable stream from a file located at the provided file path.
If the file path is blank or points to non existent file, the method will result in an error.
Parameters:
Name | Type | Description |
---|---|---|
filePath |
string | path to the file to be read |
- Source:
Throws:
-
if the file path is not provided or no file exists for it
- Type
- Error
Returns:
stream with the file data
- Type
- ReadableStream