Skip to content

Commit 03d138f

Browse files
RamdohokarAnghaalexfernandez
RamdohokarAngha
authored andcommitted
doc: fix description of fs.readdir recursive option
PR-URL: nodejs#48902 Fixes: nodejs#48640 Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Yagiz Nizipli <[email protected]> Reviewed-By: Antoine du Hamel <[email protected]>
1 parent 855b0ad commit 03d138f

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

doc/api/fs.md

+9-3
Original file line numberDiff line numberDiff line change
@@ -1322,7 +1322,9 @@ changes:
13221322
* `options` {string|Object}
13231323
* `encoding` {string} **Default:** `'utf8'`
13241324
* `withFileTypes` {boolean} **Default:** `false`
1325-
* `recursive` {boolean} **Default:** `false`
1325+
* `recursive` {boolean} If `true`, reads the contents of a directory
1326+
recursively. In recursive mode, it will list all files, sub files, and
1327+
directories. **Default:** `false`.
13261328
* Returns: {Promise} Fulfills with an array of the names of the files in
13271329
the directory excluding `'.'` and `'..'`.
13281330
@@ -3644,7 +3646,9 @@ changes:
36443646
* `options` {string|Object}
36453647
* `encoding` {string} **Default:** `'utf8'`
36463648
* `withFileTypes` {boolean} **Default:** `false`
3647-
* `recursive` {boolean} **Default:** `false`
3649+
* `recursive` {boolean} If `true`, reads the contents of a directory
3650+
recursively. In recursive mode, it will list all files, sub files and
3651+
directories. **Default:** `false`.
36483652
* `callback` {Function}
36493653
* `err` {Error}
36503654
* `files` {string\[]|Buffer\[]|fs.Dirent\[]}
@@ -5717,7 +5721,9 @@ changes:
57175721
* `options` {string|Object}
57185722
* `encoding` {string} **Default:** `'utf8'`
57195723
* `withFileTypes` {boolean} **Default:** `false`
5720-
* `recursive` {boolean} **Default:** `false`
5724+
* `recursive` {boolean} If `true`, reads the contents of a directory
5725+
recursively. In recursive mode, it will list all files, sub files, and
5726+
directories. **Default:** `false`.
57215727
* Returns: {string\[]|Buffer\[]|fs.Dirent\[]}
57225728
57235729
Reads the contents of the directory.

0 commit comments

Comments
 (0)