| hide_title | true |
|---|---|
| custom_edit_url | |
| pagination_prev | |
| pagination_next |
Home > @rushstack/node-core-library > FileSystem > createWriteStream
Creates a writable stream for writing to a file. Behind the scenes it uses fs.createWriteStream()<></>.
Signature:
static createWriteStream(filePath: string, options?: IFileSystemCreateWriteStreamOptions): FileSystemWriteStream;|
Parameter |
Type |
Description |
|---|---|---|
|
filePath |
string |
The path to the file. The path may be absolute or relative. |
|
options |
(Optional) Optional settings that can change the behavior. |
Returns:
A new writable stream for the file.
Throws an error if the folder doesn't exist, unless IFileSystemWriteFileOptionsBase.ensureFolderExists is set to true<></>.