Skip to content
This repository has been archived by the owner on Apr 22, 2023. It is now read-only.

doc: a handful of doc improvements #25565

Closed
wants to merge 7 commits into from

Conversation

jasnell
Copy link
Member

@jasnell jasnell commented Jun 24, 2015

Four separate doc improvements covering various issues. I've bundled these up
as separate commits within a single PR to make it easier to land.

jasnell and others added 4 commits June 23, 2015 20:42
Per nodejs#4409, the documentation on http.abort is a bit lacking.
This provides a slight improvement.
The documentation for createWriteStream() references an
'encoding' property that has a default value of null. However,
this property is never referenced by createWriteStream() or
WritableState(). Instead a 'defaultEncoding' property is
referenced in WritableState() with a default of 'utf8' if no value
is supplied.

This fix updates the documentation to rename the 'encoding'
property to 'defaultEncoding' and indicate its default value of
'utf8'.
@jasnell
Copy link
Member Author

jasnell commented Jun 25, 2015

@joyent/node-tsc ... can I get a quick review on these doc changes?

@@ -64,7 +64,7 @@ It can be constructed in a variety of ways.

Allocates a new buffer of `size` octets. Note, `size` must be no more than
[kMaxLength](smalloc.html#smalloc_smalloc_kmaxlength). Otherwise, a `RangeError`
will be thrown here.
will be thrown here. Unlike `ArrayBuffers`, the underlying memory for buffers is not initialized. So the contents of a newly created `Buffer` is unknown. Use `buf.fill(0)`to initialize a buffer to zeroes.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reads well. I'd suggest word wrapping the same as above.

@trevnorris
Copy link

One nit. Otherwise LGTM.

Fix the line wrapping in buffer.markdown
@jasnell
Copy link
Member Author

jasnell commented Jun 25, 2015

@trevnorris ... better? (I'll squash down the commits before landing)

@trevnorris
Copy link

looks great.

Original: nodejs#8682

Slightly modified version of the original PR (nodejs#8682) to add
appropriate line wrapping and fix a couple of grammar nits.
jasnell added a commit that referenced this pull request Jun 26, 2015
Per #4409, the documentation on http.abort is a bit lacking.
This provides a slight improvement.

Reviewed-By: James M Snell <[email protected]>
PR-URL: #25565
jasnell added a commit that referenced this pull request Jun 26, 2015
jasnell added a commit that referenced this pull request Jun 26, 2015
jasnell pushed a commit that referenced this pull request Jun 26, 2015
The documentation for createWriteStream() references an
'encoding' property that has a default value of null. However,
this property is never referenced by createWriteStream() or
WritableState(). Instead a 'defaultEncoding' property is
referenced in WritableState() with a default of 'utf8' if no value
is supplied.

This fix updates the documentation to rename the 'encoding'
property to 'defaultEncoding' and indicate its default value of
'utf8'.

Reviewed-By: James M Snell <[email protected]>
PR-URL: #25565
jasnell pushed a commit that referenced this pull request Jun 26, 2015
jasnell added a commit that referenced this pull request Jun 26, 2015
Fix the line wrapping in buffer.markdown

Reviewed-By: James M Snell <[email protected]>
PR-URL: #25565
jasnell added a commit that referenced this pull request Jun 26, 2015
Original: #8682

Slightly modified version of the original PR (#8682) to add
appropriate line wrapping and fix a couple of grammar nits.

Reviewed-By: James M Snell <[email protected]>
PR-URL: #25565
@jasnell
Copy link
Member Author

jasnell commented Jun 26, 2015

Landed in b4a0ca2, 1b027ee, ba6c086, e7f4237, 70efdf3, 500ff56, and b436e59

@jasnell jasnell closed this Jun 26, 2015
jasnell added a commit to jasnell/node-joyent that referenced this pull request Jun 29, 2015
Per nodejs#4409, the documentation on http.abort is a bit lacking.
This provides a slight improvement.

Reviewed-By: James M Snell <[email protected]>
PR-URL: nodejs#25565
jasnell added a commit to jasnell/node-joyent that referenced this pull request Jun 29, 2015
jasnell added a commit to jasnell/node-joyent that referenced this pull request Jun 29, 2015
jasnell pushed a commit to jasnell/node-joyent that referenced this pull request Jun 29, 2015
The documentation for createWriteStream() references an
'encoding' property that has a default value of null. However,
this property is never referenced by createWriteStream() or
WritableState(). Instead a 'defaultEncoding' property is
referenced in WritableState() with a default of 'utf8' if no value
is supplied.

This fix updates the documentation to rename the 'encoding'
property to 'defaultEncoding' and indicate its default value of
'utf8'.

Reviewed-By: James M Snell <[email protected]>
PR-URL: nodejs#25565
jasnell pushed a commit to jasnell/node-joyent that referenced this pull request Jun 29, 2015
jasnell added a commit to jasnell/node-joyent that referenced this pull request Jun 29, 2015
Fix the line wrapping in buffer.markdown

Reviewed-By: James M Snell <[email protected]>
PR-URL: nodejs#25565
jasnell added a commit to jasnell/node-joyent that referenced this pull request Jun 29, 2015
Original: nodejs#8682

Slightly modified version of the original PR (nodejs#8682) to add
appropriate line wrapping and fix a couple of grammar nits.

Reviewed-By: James M Snell <[email protected]>
PR-URL: nodejs#25565
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants