-
Notifications
You must be signed in to change notification settings - Fork 30.2k
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
Clarify "fs.readFile", "fs.appendFile", "fs.writeFile" doc… #7561
Closed
Closed
Changes from 4 commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
e4a8d56
refs #7560 Clarify "fs.readFile", "fs.appendFile", "fs.writeFile" doc…
kibertoad a851058
refs #7560 Use backticks instead of single quotes.
kibertoad 40a5750
refs #7560 Merge two notes, wrap at 80 symbols.
kibertoad 7e617e0
refs #7560 Add missing "the".
kibertoad b5baaa2
refs #7560 Removed excessive detail about internal implementation.
kibertoad File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If the same text has to be repeated multiple times, wouldn't it be better to have it as a separate section and link it wherever necessary?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not such a long text and it didn't bother anyone about the original text. Wouldn't it unnecessarily complicate things? Are there any existing precedents of similar treatment of three-liners?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Btw, while that second sentence is true, I’m not sure it’s actually relevant; that writing to a file based on its name includes opening and closing a file descriptor seems like an implementation detail to me which the user doesn’t need to know anything about.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fair enough. Do you think that the second sentence should be removed altogether? I'm not entirely sure there is no value in explicitly telling the user that he doesn't need to worry about releasing resources in some of the use cases (as opposed to another documented case when he, indeed, should worry), but if you think that it's already implied in a clear enough way in the first sentence, I'm fine with dropping it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I’d be pretty fine with dropping it, too. The first sentence seems clear enough to me.