Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: clarify fs.write[Sync]() descriptions #22402

Closed
wants to merge 1 commit into from
Closed

doc: clarify fs.write[Sync]() descriptions #22402

wants to merge 1 commit into from

Commits on Aug 19, 2018

  1. doc: clarify fs.write[Sync]() descriptions

    1. All default values for optional `encoding` parameters
       were documented except for the one in `fs.write(fd, string...)`
       method. This PR makes up this deficiency.
    
       Refs: https://github.com/nodejs/node/blob/a04f2f7df630427bf869b1e04040975b752973b6/lib/fs.js#L549
    
    2. We have two variants of `fs.write()` / `fs.writeSync()` methods:
       for buffers and strings. Currently, the sync methods have only one
       common reference to the full description of async methods.
       However, the link may seem to belong to the last sync variant only
       (for strings) and, as it refers to the first async variant
       (for buffers), this may be confusing. This PR makes two different
       sync variants refer to two different async variants.
    
    3. In passing, both returned values of sync methods were also made
       more concise and unambiguous.
    vsemozhetbyt committed Aug 19, 2018
    Configuration menu
    Copy the full SHA
    5d9003a View commit details
    Browse the repository at this point in the history