Skip to content

Commit 5dd7ba6

Browse files
authored
doc: get rid of unnecessary eslint-skip comments
PR-URL: nodejs#50829 Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Ethan Arrowood <[email protected]> Reviewed-By: Yagiz Nizipli <[email protected]> Reviewed-By: Paolo Insogna <[email protected]> Reviewed-By: Tobias Nießen <[email protected]> Reviewed-By: Marco Ippolito <[email protected]>
1 parent 041d435 commit 5dd7ba6

File tree

7 files changed

+14
-24
lines changed

7 files changed

+14
-24
lines changed

doc/api/crypto.md

+3-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ calling `require('node:crypto')` will result in an error being thrown.
4242

4343
When using CommonJS, the error thrown can be caught using try/catch:
4444

45-
<!-- eslint-skip -->
45+
<!-- eslint-disable no-global-assign -->
4646

4747
```cjs
4848
let crypto;
@@ -53,6 +53,8 @@ try {
5353
}
5454
```
5555

56+
<!-- eslint-enable no-global-assign -->
57+
5658
When using the lexical ESM `import` keyword, the error can only be
5759
caught if a handler for `process.on('uncaughtException')` is registered
5860
_before_ any attempt to load the module is made (using, for instance,

doc/api/errors.md

+1-3
Original file line numberDiff line numberDiff line change
@@ -2940,9 +2940,7 @@ signal (such as [`subprocess.kill()`][]).
29402940
[self-reference a package using its name][] and [define a custom subpath][] in
29412941
the [`"exports"`][] field of the [`package.json`][] file.
29422942

2943-
<!-- eslint-skip -->
2944-
2945-
```js
2943+
```mjs
29462944
import './'; // unsupported
29472945
import './index.js'; // supported
29482946
import 'package-name'; // supported

doc/api/http.md

+6-8
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,12 @@ user is able to stream data.
1616

1717
HTTP message headers are represented by an object like this:
1818

19-
<!-- eslint-skip -->
20-
21-
```js
22-
{ 'content-length': '123',
23-
'content-type': 'text/plain',
24-
'connection': 'keep-alive',
25-
'host': 'example.com',
26-
'accept': '*/*' }
19+
```json
20+
{ "content-length": "123",
21+
"content-type": "text/plain",
22+
"connection": "keep-alive",
23+
"host": "example.com",
24+
"accept": "*/*" }
2725
```
2826

2927
Keys are lowercased. Values are not modified.

doc/api/https.md

-2
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,6 @@ calling `require('node:https')` will result in an error being thrown.
1717

1818
When using CommonJS, the error thrown can be caught using try/catch:
1919

20-
<!-- eslint-skip -->
21-
2220
```cjs
2321
let https;
2422
try {

doc/api/querystring.md

+3-5
Original file line numberDiff line numberDiff line change
@@ -87,12 +87,10 @@ collection of key and value pairs.
8787

8888
For example, the query string `'foo=bar&abc=xyz&abc=123'` is parsed into:
8989

90-
<!-- eslint-skip -->
91-
92-
```js
90+
```json
9391
{
94-
foo: 'bar',
95-
abc: ['xyz', '123']
92+
"foo": "bar",
93+
"abc": ["xyz", "123"]
9694
}
9795
```
9896

doc/api/tls.md

-2
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,6 @@ calling `require('node:tls')` will result in an error being thrown.
2222

2323
When using CommonJS, the error thrown can be caught using try/catch:
2424

25-
<!-- eslint-skip -->
26-
2725
```cjs
2826
let tls;
2927
try {

doc/api/util.md

+1-3
Original file line numberDiff line numberDiff line change
@@ -2513,9 +2513,7 @@ added: v10.0.0
25132513
25142514
Returns `true` if the value is an instance of a [Module Namespace Object][].
25152515
2516-
<!-- eslint-skip -->
2517-
2518-
```js
2516+
```mjs
25192517
import * as ns from './a.js';
25202518

25212519
util.types.isModuleNamespaceObject(ns); // Returns true

0 commit comments

Comments
 (0)