From 04eed2342d8e51d12041541ca88a70ff83b9fad9 Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Tue, 3 Jul 2018 16:51:28 -0700 Subject: [PATCH] doc: remove "note that" from fs doc MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Remove "note that" from the fs documentation, along with other minor nearby improvements. Before: Note that some characters are obscured by Strong Bad's head. After: Some characters are obscured by Strong Bad's head. PR-URL: https://github.com/nodejs/node/pull/21646 Reviewed-By: Trivikram Kamat Reviewed-By: Сковорода Никита Андреевич Reviewed-By: Colin Ihrig Reviewed-By: Vse Mozhet Byt Reviewed-By: Luigi Pinca Reviewed-By: Michael Dawson --- doc/api/fs.md | 118 ++++++++++++++++++++++++-------------------------- 1 file changed, 56 insertions(+), 62 deletions(-) diff --git a/doc/api/fs.md b/doc/api/fs.md index 2adbf6fb58cb7b..e159ec573c6664 100644 --- a/doc/api/fs.md +++ b/doc/api/fs.md @@ -45,9 +45,9 @@ try { } ``` -Note that there is no guaranteed ordering when using asynchronous methods. -So the following is prone to error because the `fs.stat()` operation may -complete before the `fs.rename()` operation. +There is no guaranteed ordering when using asynchronous methods. So the +following is prone to error because the `fs.stat()` operation may complete +before the `fs.rename()` operation: ```js fs.rename('/tmp/hello', '/tmp/world', (err) => { @@ -150,8 +150,8 @@ fs.open(Buffer.from('/open/some/file.txt'), 'r', (err, fd) => { }); ``` -*Note:* On Windows Node.js follows the concept of per-drive working directory. -This behavior can be observed when using a drive path without a backslash. For +On Windows, Node.js follows the concept of per-drive working directory. This +behavior can be observed when using a drive path without a backslash. For example `fs.readdirSync('c:\\')` can potentially return a different result than `fs.readdirSync('c:')`. For more information, see [this MSDN page][MSDN-Rel-Path]. @@ -278,9 +278,9 @@ eventually cause an application to crash. ## Threadpool Usage -Note that all file system APIs except `fs.FSWatcher()` and those that are -explicitly synchronous use libuv's threadpool, which can have surprising and -negative performance implications for some applications, see the +All file system APIs except `fs.FSWatcher()` and those that are explicitly +synchronous use libuv's threadpool, which can have surprising and negative +performance implications for some applications. See the [`UV_THREADPOOL_SIZE`][] documentation for more information. ## Class: fs.FSWatcher @@ -689,15 +689,13 @@ The times in the stat object have the following semantics: * `birthtime` "Birth Time" - Time of file creation. Set once when the file is created. On filesystems where birthtime is not available, this field may instead hold either the `ctime` or - `1970-01-01T00:00Z` (ie, unix epoch timestamp `0`). Note that this - value may be greater than `atime` or `mtime` in this case. On Darwin - and other FreeBSD variants, also set if the `atime` is explicitly - set to an earlier value than the current `birthtime` using the - utimes(2) system call. + `1970-01-01T00:00Z` (ie, unix epoch timestamp `0`). This value may be greater + than `atime` or `mtime` in this case. On Darwin and other FreeBSD variants, + also set if the `atime` is explicitly set to an earlier value than the current + `birthtime` using the utimes(2) system call. -Prior to Node.js v0.12, the `ctime` held the `birthtime` on Windows -systems. Note that as of v0.12, `ctime` is not "creation time", and -on Unix systems, it never was. +Prior to Node.js 0.12, the `ctime` held the `birthtime` on Windows systems. As +of 0.12, `ctime` is not "creation time", and on Unix systems, it never was. ## Class: fs.WriteStream