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: unify section structures #20028

Closed
wants to merge 1 commit into from
Closed

doc: unify section structures #20028

wants to merge 1 commit into from

Conversation

vsemozhetbyt
Copy link
Contributor

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • documentation is changed or added
  • commit message follows commit guidelines

We had two docs with slight deviations from the common section structure concerning:

  • class <-> constructor hierarchy;
  • method's callback signature and description.

There are 'before' and 'after' states:

  1. string_decoder.md
String Decoder
  Class: new StringDecoder([encoding])
    stringDecoder.end([buffer])
    stringDecoder.write(buffer)
String Decoder
  Class: StringDecoder
    new StringDecoder([encoding])
    stringDecoder.end([buffer])
    stringDecoder.write(buffer)
  1. perf_hooks.md
Class: PerformanceObserver(callback)
  Callback: PerformanceObserverCallback(list, observer)
  Class: PerformanceObserverEntryList
    performanceObserverEntryList.getEntries()
    performanceObserverEntryList.getEntriesByName(name[, type])
    performanceObserverEntryList.getEntriesByType(type)
  performanceObserver.disconnect()
  performanceObserver.observe(options)
Examples
Class: PerformanceObserver
  new PerformanceObserver(callback)
  performanceObserver.disconnect()
  performanceObserver.observe(options)
Class: PerformanceObserverEntryList
  performanceObserverEntryList.getEntries()
  performanceObserverEntryList.getEntriesByName(name[, type])
  performanceObserverEntryList.getEntriesByType(type)
Examples

with Callback: PerformanceObserverCallback(list, observer) incorporated in the parent section as we usually do for all the callbacks.

These changes also help tools/doc/json.js to parse and JSON-ize the docs more properly.

@vsemozhetbyt vsemozhetbyt added the fast-track PRs that do not need to wait for 48 hours to land. label Apr 14, 2018
@nodejs-github-bot nodejs-github-bot added doc Issues and PRs related to the documentations. tools Issues and PRs related to the tools directory. labels Apr 14, 2018
@vsemozhetbyt
Copy link
Contributor Author

Copy link
Member

@trivikr trivikr left a comment

Choose a reason for hiding this comment

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

Verified the documentation update in private branch

@vsemozhetbyt
Copy link
Contributor Author

Landed in 715d7f3

@vsemozhetbyt vsemozhetbyt deleted the doc-unify-structures branch April 14, 2018 23:40
vsemozhetbyt added a commit that referenced this pull request Apr 14, 2018
PR-URL: #20028
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
jasnell pushed a commit that referenced this pull request Apr 16, 2018
PR-URL: #20028
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
BridgeAR pushed a commit to BridgeAR/node that referenced this pull request May 1, 2018
PR-URL: nodejs#20028
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
doc Issues and PRs related to the documentations. fast-track PRs that do not need to wait for 48 hours to land. tools Issues and PRs related to the tools directory.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants