Skip to content

Commit

Permalink
doc: use blockquotes for Stability: markers
Browse files Browse the repository at this point in the history
Use blockquotes instead of code blocks for stability markers in
the docs. Doing that:

- Makes the makers appear correctly when viewed e.g. on github.
- Allows remark-lint rules like `no-undefined-references` to work
  properly (nodejs#7729).
  • Loading branch information
addaleax committed Jul 15, 2016
1 parent 6510eb5 commit 292dd07
Show file tree
Hide file tree
Showing 36 changed files with 127 additions and 114 deletions.
2 changes: 1 addition & 1 deletion doc/api/assert.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Assert

Stability: 3 - Locked
> Stability: 3 - Locked
The `assert` module provides a simple set of assertion tests that can be used to
test invariants. The module is intended for internal use by Node.js, but can be
Expand Down
34 changes: 17 additions & 17 deletions doc/api/buffer.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Buffer

Stability: 2 - Stable
> Stability: 2 - Stable
Prior to the introduction of `TypedArray` in ECMAScript 2015 (ES6), the
JavaScript language had no mechanism for reading or manipulating streams
Expand Down Expand Up @@ -277,8 +277,8 @@ It can be constructed in a variety of ways.
deprecated: v6.0.0
-->

Stability: 0 - Deprecated: Use [`Buffer.from(array)`][buffer_from_array]
instead.
> Stability: 0 - Deprecated: Use [`Buffer.from(array)`][buffer_from_array]
> instead.
* `array` {Array}

Expand All @@ -295,8 +295,8 @@ const buf = new Buffer([0x62,0x75,0x66,0x66,0x65,0x72]);
deprecated: v6.0.0
-->

Stability: 0 - Deprecated: Use [`Buffer.from(buffer)`][buffer_from_buffer]
instead.
> Stability: 0 - Deprecated: Use [`Buffer.from(buffer)`][buffer_from_buffer]
> instead.
* `buffer` {Buffer}

Expand All @@ -318,9 +318,9 @@ console.log(buf2.toString());
deprecated: v6.0.0
-->

Stability: 0 - Deprecated: Use
[`Buffer.from(arrayBuffer[, byteOffset [, length]])`][buffer_from_arraybuf]
instead.
> Stability: 0 - Deprecated: Use
> [`Buffer.from(arrayBuffer[, byteOffset [, length]])`][buffer_from_arraybuf]
> instead.
* `arrayBuffer` {ArrayBuffer} The `.buffer` property of a `TypedArray` or a
`new ArrayBuffer()`
Expand Down Expand Up @@ -356,9 +356,9 @@ console.log(buf);
deprecated: v6.0.0
-->

Stability: 0 - Deprecated: Use
[`Buffer.alloc(size[, fill[, encoding]])`][buffer_alloc] instead (also
see [`Buffer.allocUnsafe(size)`][buffer_allocunsafe]).
> Stability: 0 - Deprecated: Use
> [`Buffer.alloc(size[, fill[, encoding]])`][buffer_alloc] instead (also
> see [`Buffer.allocUnsafe(size)`][buffer_allocunsafe]).
* `size` {Number}

Expand Down Expand Up @@ -388,8 +388,8 @@ console.log(buf);
deprecated: v6.0.0
-->

Stability: 0 - Deprecated:
Use [`Buffer.from(str[, encoding])`][buffer_from_string] instead.
> Stability: 0 - Deprecated:
> Use [`Buffer.from(str[, encoding])`][buffer_from_string] instead.
* `str` {String} string to encode.
* `encoding` {String} Default: `'utf8'`
Expand Down Expand Up @@ -1954,8 +1954,8 @@ Note that this is a property on the `buffer` module as returned by
deprecated: v6.0.0
-->

Stability: 0 - Deprecated: Use
[`Buffer.allocUnsafeSlow(size)`][buffer_allocunsafeslow] instead.
> Stability: 0 - Deprecated: Use
> [`Buffer.allocUnsafeSlow(size)`][buffer_allocunsafeslow] instead.
Returns an un-pooled `Buffer`.

Expand Down Expand Up @@ -1990,8 +1990,8 @@ has observed undue memory retention in their applications.
deprecated: v6.0.0
-->

Stability: 0 - Deprecated: Use
[`Buffer.allocUnsafeSlow(size)`][buffer_allocunsafeslow] instead.
> Stability: 0 - Deprecated: Use
> [`Buffer.allocUnsafeSlow(size)`][buffer_allocunsafeslow] instead.
* `size` Number

Expand Down
2 changes: 1 addition & 1 deletion doc/api/child_process.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Child Process

Stability: 2 - Stable
> Stability: 2 - Stable
The `child_process` module provides the ability to spawn child processes in
a manner that is similar, but not identical, to popen(3). This capability
Expand Down
4 changes: 2 additions & 2 deletions doc/api/cluster.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Cluster

Stability: 2 - Stable
> Stability: 2 - Stable
A single instance of Node.js runs in a single thread. To take advantage of
multi-core systems the user will sometimes want to launch a cluster of Node.js
Expand Down Expand Up @@ -395,7 +395,7 @@ if (cluster.isMaster) {

### worker.suicide

Stability: 0 - Deprecated: Use [`worker.exitedAfterDisconnect`][] instead.
> Stability: 0 - Deprecated: Use [`worker.exitedAfterDisconnect`][] instead.
An alias to [`worker.exitedAfterDisconnect`][].

Expand Down
2 changes: 1 addition & 1 deletion doc/api/console.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Console

Stability: 2 - Stable
> Stability: 2 - Stable
The `console` module provides a simple debugging console that is similar to the
JavaScript console mechanism provided by web browsers.
Expand Down
6 changes: 3 additions & 3 deletions doc/api/crypto.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Crypto

Stability: 2 - Stable
> Stability: 2 - Stable
The `crypto` module provides cryptographic functionality that includes a set of
wrappers for OpenSSL's hash, HMAC, cipher, decipher, sign and verify functions.
Expand Down Expand Up @@ -510,7 +510,7 @@ public point (key) is also generated and set in the ECDH object.

### ecdh.setPublicKey(public_key[, encoding])

Stability: 0 - Deprecated
> Stability: 0 - Deprecated
Sets the EC Diffie-Hellman public key. Key encoding can be `'latin1'`,
`'hex'` or `'base64'`. If `encoding` is provided `public_key` is expected to
Expand Down Expand Up @@ -918,7 +918,7 @@ The `key` is the raw key used by the `algorithm` and `iv` is an

### crypto.createCredentials(details)

Stability: 0 - Deprecated: Use [`tls.createSecureContext()`][] instead.
> Stability: 0 - Deprecated: Use [`tls.createSecureContext()`][] instead.
The `crypto.createCredentials()` method is a deprecated alias for creating
and returning a `tls.SecureContext` object. The `crypto.createCredentials()`
Expand Down
2 changes: 1 addition & 1 deletion doc/api/debugger.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Debugger

Stability: 2 - Stable
> Stability: 2 - Stable
<!-- type=misc -->

Expand Down
2 changes: 1 addition & 1 deletion doc/api/dgram.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# UDP / Datagram Sockets

Stability: 2 - Stable
> Stability: 2 - Stable
<!-- name=dgram -->

Expand Down
2 changes: 1 addition & 1 deletion doc/api/dns.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# DNS

Stability: 2 - Stable
> Stability: 2 - Stable
The `dns` module contains functions belonging to two different categories:

Expand Down
42 changes: 17 additions & 25 deletions doc/api/documentation.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,34 +37,26 @@ and in the process of being redesigned.

The stability indices are as follows:

```txt
Stability: 0 - Deprecated
This feature is known to be problematic, and changes are
planned. Do not rely on it. Use of the feature may cause warnings. Backwards
compatibility should not be expected.
```

```txt
Stability: 1 - Experimental
This feature is subject to change, and is gated by a command line flag.
It may change or be removed in future versions.
```

```txt
Stability: 2 - Stable
The API has proven satisfactory. Compatibility with the npm ecosystem
is a high priority, and will not be broken unless absolutely necessary.
```

```txt
Stability: 3 - Locked
Only fixes related to security, performance, or bug fixes will be accepted.
Please do not suggest API changes in this area; they will be refused.
```
> Stability: 0 - Deprecated
> This feature is known to be problematic, and changes are
> planned. Do not rely on it. Use of the feature may cause warnings. Backwards
> compatibility should not be expected.
> Stability: 1 - Experimental
> This feature is subject to change, and is gated by a command line flag.
> It may change or be removed in future versions.
> Stability: 2 - Stable
> The API has proven satisfactory. Compatibility with the npm ecosystem
> is a high priority, and will not be broken unless absolutely necessary.
> Stability: 3 - Locked
> Only fixes related to security, performance, or bug fixes will be accepted.
> Please do not suggest API changes in this area; they will be refused.
## JSON Output

Stability: 1 - Experimental
> Stability: 1 - Experimental
Every HTML file in the markdown has a corresponding JSON file with the
same data.
Expand Down
4 changes: 2 additions & 2 deletions doc/api/domain.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Domain

Stability: 0 - Deprecated
> Stability: 0 - Deprecated
**This module is pending deprecation**. Once a replacement API has been
finalized, this module will be fully deprecated. Most end users should
Expand Down Expand Up @@ -436,7 +436,7 @@ without exiting the domain.

### domain.dispose()

Stability: 0 - Deprecated. Please recover from failed IO actions
> Stability: 0 - Deprecated. Please recover from failed IO actions
explicitly via error event handlers set on the domain.

Once `dispose` has been called, the domain will no longer be used by callbacks
Expand Down
4 changes: 2 additions & 2 deletions doc/api/events.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Events

Stability: 2 - Stable
> Stability: 2 - Stable
<!--type=module-->

Expand Down Expand Up @@ -223,7 +223,7 @@ The `'removeListener'` event is emitted *after* a listener is removed.

### EventEmitter.listenerCount(emitter, eventName)

Stability: 0 - Deprecated: Use [`emitter.listenerCount()`][] instead.
> Stability: 0 - Deprecated: Use [`emitter.listenerCount()`][] instead.
A class method that returns the number of listeners for the given `eventName`
registered on the given `emitter`.
Expand Down
8 changes: 4 additions & 4 deletions doc/api/fs.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# File System

Stability: 2 - Stable
> Stability: 2 - Stable
<!--name=fs-->

Expand Down Expand Up @@ -584,7 +584,7 @@ added: v0.0.2
deprecated: v1.0.0
-->

Stability: 0 - Deprecated: Use [`fs.stat()`][] or [`fs.access()`][] instead.
> Stability: 0 - Deprecated: Use [`fs.stat()`][] or [`fs.access()`][] instead.
* `path` {String | Buffer}
* `callback` {Function}
Expand All @@ -610,8 +610,8 @@ added: v0.1.21
deprecated: v1.0.0
-->

Stability: 0 - Deprecated: Use [`fs.statSync()`][] or [`fs.accessSync()`][]
instead.
> Stability: 0 - Deprecated: Use [`fs.statSync()`][] or [`fs.accessSync()`][]
> instead.
* `path` {String | Buffer}

Expand Down
2 changes: 1 addition & 1 deletion doc/api/globals.md
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ Error.

### require.extensions

Stability: 0 - Deprecated
> Stability: 0 - Deprecated
* {Object}

Expand Down
4 changes: 2 additions & 2 deletions doc/api/http.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# HTTP

Stability: 2 - Stable
> Stability: 2 - Stable
To use the HTTP server and client one must `require('http')`.

Expand Down Expand Up @@ -1331,7 +1331,7 @@ added: v0.1.13
deprecated: v0.3.6
-->

Stability: 0 - Deprecated: Use [`http.request()`][] instead.
> Stability: 0 - Deprecated: Use [`http.request()`][] instead.
Constructs a new HTTP client. `port` and `host` refer to the server to be
connected to.
Expand Down
2 changes: 1 addition & 1 deletion doc/api/https.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# HTTPS

Stability: 2 - Stable
> Stability: 2 - Stable
HTTPS is the HTTP protocol over TLS/SSL. In Node.js this is implemented as a
separate module.
Expand Down
2 changes: 1 addition & 1 deletion doc/api/modules.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Modules

Stability: 3 - Locked
> Stability: 3 - Locked
<!--name=module-->

Expand Down
4 changes: 2 additions & 2 deletions doc/api/net.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# net

Stability: 2 - Stable
> Stability: 2 - Stable
The `net` module provides you with an asynchronous network wrapper. It contains
functions for creating both servers and clients (called streams). You can include
Expand Down Expand Up @@ -98,7 +98,7 @@ added: v0.2.0
deprecated: v0.9.7
-->

Stability: 0 - Deprecated: Use [`server.getConnections()`][] instead.
> Stability: 0 - Deprecated: Use [`server.getConnections()`][] instead.
The number of concurrent connections on the server.

Expand Down
2 changes: 1 addition & 1 deletion doc/api/os.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# OS

Stability: 2 - Stable
> Stability: 2 - Stable
The `os` module provides a number of operating system-related utility methods.
It can be accessed using:
Expand Down
2 changes: 1 addition & 1 deletion doc/api/path.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Path

Stability: 2 - Stable
> Stability: 2 - Stable
The `path` module provides utilities for working with file and directory paths.
It can be accessed using:
Expand Down
2 changes: 1 addition & 1 deletion doc/api/punycode.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# punycode

Stability: 2 - Stable
> Stability: 2 - Stable
The `punycode` module is a bundled version of the [Punycode.js][] module. It
can be accessed using:
Expand Down
2 changes: 1 addition & 1 deletion doc/api/querystring.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Query String

Stability: 2 - Stable
> Stability: 2 - Stable
<!--name=querystring-->

Expand Down
2 changes: 1 addition & 1 deletion doc/api/readline.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Readline

Stability: 2 - Stable
> Stability: 2 - Stable
The `readline` module provides an interface for reading data from a [Readable][]
stream (such as [`process.stdin`]) one line at a time. It can be accessed using:
Expand Down
Loading

0 comments on commit 292dd07

Please sign in to comment.