Skip to content
Merged
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
3 changes: 3 additions & 0 deletions doc/api/fs.md
Original file line number Diff line number Diff line change
Expand Up @@ -4126,6 +4126,9 @@ Asynchronous stat(2). The callback gets two arguments `(err, stats)` where

In case of an error, the `err.code` will be one of [Common System Errors][].

[`fs.stat()`][] follows symbolic links. Use [`fs.lstat()`][] to look at the
links themselves.

Using `fs.stat()` to check for the existence of a file before calling
`fs.open()`, `fs.readFile()`, or `fs.writeFile()` is not recommended.
Instead, user code should open/read/write the file directly and handle the
Expand Down