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

docs: fix cli.md and delint #14707

Merged
merged 2 commits into from
Aug 14, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion doc/api/cli.md
Expand Up @@ -185,7 +185,7 @@ added: v8.0.0
Enable loading native modules compiled with the ABI-stable Node.js API (N-API)
(experimental).

## `--abort-on-uncaught-exception`
### `--abort-on-uncaught-exception`
<!-- YAML
added: v0.10
-->
Expand Down
18 changes: 9 additions & 9 deletions doc/api/http2.md
Expand Up @@ -1850,8 +1850,8 @@ const server = http2.createServer((req, res) => {
});
```

In order to create a mixed [HTTPS](https) and HTTP/2 server, refer to the
[ALPN negotiation](alpn-negotiation) section.
In order to create a mixed [HTTPS][] and HTTP/2 server, refer to the
[ALPN negotiation][] section.
Upgrading from non-tls HTTP/1 servers is not supported.

The HTTP2 compatibility API is composed of [`Http2ServerRequest`]() and
Expand All @@ -1861,10 +1861,10 @@ the status message for HTTP codes is ignored.

### ALPN negotiation

ALPN negotiation allows to support both [HTTPS](https) and HTTP/2 over
ALPN negotiation allows to support both [HTTPS][] and HTTP/2 over
the same socket. The `req` and `res` objects can be either HTTP/1 or
HTTP/2, and an application **must** restrict itself to the public API of
[HTTP/1](), and detect if it is possible to use the more advanced
[HTTP/1][], and detect if it is possible to use the more advanced
features of HTTP/2.

The following example creates a server that supports both protocols:
Expand Down Expand Up @@ -1925,7 +1925,7 @@ abnormally aborted in mid-communication.
added: REPLACEME
-->

Indicates that the underlying [`Http2Stream`]() was closed.
Indicates that the underlying [`Http2Stream`][] was closed.
Just like `'end'`, this event occurs only once per response.

#### request.destroy([error])
Expand All @@ -1935,7 +1935,7 @@ added: REPLACEME

* `error` {Error}

Calls `destroy()` on the [Http2Stream]() that received the `ServerRequest`. If
Calls `destroy()` on the [`Http2Stream`][] that received the [`ServerRequest`][]. If
`error` is provided, an `'error'` event is emitted and `error` is passed as an
argument to any listeners on the event.

Expand Down Expand Up @@ -2570,21 +2570,21 @@ will result in a [`TypeError`][] being thrown.
added: REPLACEME
-->

Call [`stream.pushStream()`]() with the given headers, and wraps the
Call [`stream.pushStream()`][] with the given headers, and wraps the
given newly created [`Http2Stream`] on `Http2ServerRespose`.

The callback will be called with an error with code `ERR_HTTP2_STREAM_CLOSED`
if the stream is closed.

[HTTP/2]: https://tools.ietf.org/html/rfc7540
[HTTP/1]: http.html
[https]: https.html
[HTTPS]: https.html
[`net.Socket`]: net.html
[`tls.TLSSocket`]: tls.html
[`tls.createServer()`]: tls.html#tls_tls_createserver_options_secureconnectionlistener
[`ClientHttp2Stream`]: #http2_class_clienthttp2stream
[Compatibility API]: #http2_compatibility_api
[alpn-negotiation]: #http2_alpn_negotiation
[ALPN negotiation]: #http2_alpn_negotiation
[`Duplex`]: stream.html#stream_class_stream_duplex
[Headers Object]: #http2_headers_object
[`Http2Stream`]: #http2_class_http2stream
Expand Down
6 changes: 4 additions & 2 deletions doc/api/n-api.md
Expand Up @@ -342,15 +342,15 @@ to be added to the error object. If the optional parameter is NULL
then no code will be associated with the error. If a code is provided,
the name associated with the error is also updated to be:

```
```text
originalName [code]
```

where originalName is the original name associated with the error
and code is the code that was provided. For example if the code
is 'ERR_ERROR_1' and a TypeError is being created the name will be:

```
```text
TypeError [ERR_ERROR_1]
```

Expand Down Expand Up @@ -3342,6 +3342,8 @@ support it:
* If the function is not available, provide an alternate implementation
that does not use the function.

<!-- it's very convenient to have all the anchors indexed -->
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this necessary?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The comment? I felt like it wasn't obvious why the added disable no-unused-definitions, I can rephrase, also happy to take suggestions.

<!--lint disable no-unused-definitions remark-lint-->
[Asynchronous Operations]: #n_api_asynchronous_operations
[Basic N-API Data Types]: #n_api_basic_n_api_data_types
[ECMAScript Language Specification]: https://tc39.github.io/ecma262/
Expand Down