Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions doc/api/fs.md
Original file line number Diff line number Diff line change
Expand Up @@ -1569,6 +1569,16 @@ should be passed to [`net.Socket`][].

If `options` is a string, then it specifies the encoding.

```js
// Create a stream of file copy functions
const fs = require('fs');

const rs = fs.createReadStream('./out.txt');
const ws = fs.createWriteStream('./input.txt', { flags: 'a' });

rs.pipe(ws); // Out.txt content pipe to input.txt
```

## fs.exists(path, callback)
<!-- YAML
added: v0.0.2
Expand Down