| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 4458378 commit 45c70a9
26 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -11,8 +11,7 @@ provide an interface between JavaScript running in Node.js and C/C++ libraries. | |||
| 11 | 11 | There are three options for implementing Addons: N-API, nan, or direct | |
| 12 | 12 | use of internal V8, libuv and Node.js libraries. Unless you need direct | |
| 13 | 13 | access to functionality which is not exposed by N-API, use N-API. | |
| 14 | - Refer to the section [C/C++ Addons - N-API](n-api.html) | ||
| 15 | - for more information on N-API. | ||
| 14 | + Refer to [C/C++ Addons with N-API](n-api.html) for more information on N-API. | ||
| 16 | 15 | ||
| 17 | 16 | When not using N-API, implementing Addons is complicated, | |
| 18 | 17 | involving knowledge of several components and APIs: | |
@@ -435,8 +434,8 @@ NAPI_MODULE(NODE_GYP_MODULE_NAME, init) | |||
| 435 | 434 | } // namespace demo | |
| 436 | 435 | ``` | |
| 437 | 436 | ||
| 438 | - The functions available and how to use them are documented in the | ||
| 439 | - section titled [C/C++ Addons - N-API](n-api.html). | ||
| 437 | + The functions available and how to use them are documented in | ||
| 438 | + [C/C++ Addons with N-API](n-api.html). | ||
| 440 | 439 | ||
| 441 | 440 | ## Addon examples | |
| 442 | 441 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -182,28 +182,28 @@ console.log(Buffer.from('fhqwhgads', 'utf16le')); | |||
| 182 | 182 | ||
| 183 | 183 | The character encodings currently supported by Node.js include: | |
| 184 | 184 | ||
| 185 | - * `'ascii'` - For 7-bit ASCII data only. This encoding is fast and will strip | ||
| 185 | + * `'ascii'`: For 7-bit ASCII data only. This encoding is fast and will strip | ||
| 186 | 186 | the high bit if set. | |
| 187 | 187 | ||
| 188 | - * `'utf8'` - Multibyte encoded Unicode characters. Many web pages and other | ||
| 188 | + * `'utf8'`: Multibyte encoded Unicode characters. Many web pages and other | ||
| 189 | 189 | document formats use UTF-8. | |
| 190 | 190 | ||
| 191 | - * `'utf16le'` - 2 or 4 bytes, little-endian encoded Unicode characters. | ||
| 191 | + * `'utf16le'`: 2 or 4 bytes, little-endian encoded Unicode characters. | ||
| 192 | 192 | Surrogate pairs (U+10000 to U+10FFFF) are supported. | |
| 193 | 193 | ||
| 194 | - * `'ucs2'` - Alias of `'utf16le'`. | ||
| 194 | + * `'ucs2'`: Alias of `'utf16le'`. | ||
| 195 | 195 | ||
| 196 | - * `'base64'` - Base64 encoding. When creating a `Buffer` from a string, | ||
| 196 | + * `'base64'`: Base64 encoding. When creating a `Buffer` from a string, | ||
| 197 | 197 | this encoding will also correctly accept "URL and Filename Safe Alphabet" as | |
| 198 | 198 | specified in [RFC 4648, Section 5][]. | |
| 199 | 199 | ||
| 200 | - * `'latin1'` - A way of encoding the `Buffer` into a one-byte encoded string | ||
| 200 | + * `'latin1'`: A way of encoding the `Buffer` into a one-byte encoded string | ||
| 201 | 201 | (as defined by the IANA in [RFC 1345][], | |
| 202 | 202 | page 63, to be the Latin-1 supplement block and C0/C1 control codes). | |
| 203 | 203 | ||
| 204 | - * `'binary'` - Alias for `'latin1'`. | ||
| 204 | + * `'binary'`: Alias for `'latin1'`. | ||
| 205 | 205 | ||
| 206 | - * `'hex'` - Encode each byte as two hexadecimal characters. | ||
| 206 | + * `'hex'`: Encode each byte as two hexadecimal characters. | ||
| 207 | 207 | ||
| 208 | 208 | Modern Web browsers follow the [WHATWG Encoding Standard][] which aliases | |
| 209 | 209 | both `'latin1'` and `'ISO-8859-1'` to `'win-1252'`. This means that while doing | |
@@ -1003,8 +1003,8 @@ The index operator `[index]` can be used to get and set the octet at position | |||
| 1003 | 1003 | range is between `0x00` and `0xFF` (hex) or `0` and `255` (decimal). | |
| 1004 | 1004 | ||
| 1005 | 1005 | This operator is inherited from `Uint8Array`, so its behavior on out-of-bounds | |
| 1006 | - access is the same as `UInt8Array` - that is, getting returns `undefined` and | ||
| 1007 | - setting does nothing. | ||
| 1006 | + access is the same as `UInt8Array`. In other words, getting returns `undefined` | ||
| 1007 | + and setting does nothing. | ||
| 1008 | 1008 | ||
| 1009 | 1009 | ```js | |
| 1010 | 1010 | // Copy an ASCII string into a `Buffer` one byte at a time. | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -599,21 +599,21 @@ equal to `['pipe', 'pipe', 'pipe']`. | |||
| 599 | 599 | ||
| 600 | 600 | For convenience, `options.stdio` may be one of the following strings: | |
| 601 | 601 | ||
| 602 | - * `'pipe'` - equivalent to `['pipe', 'pipe', 'pipe']` (the default) | ||
| 603 | - * `'ignore'` - equivalent to `['ignore', 'ignore', 'ignore']` | ||
| 604 | - * `'inherit'` - equivalent to `['inherit', 'inherit', 'inherit']` or `[0, 1, 2]` | ||
| 602 | + * `'pipe'`: equivalent to `['pipe', 'pipe', 'pipe']` (the default) | ||
| 603 | + * `'ignore'`: equivalent to `['ignore', 'ignore', 'ignore']` | ||
| 604 | + * `'inherit'`: equivalent to `['inherit', 'inherit', 'inherit']` or `[0, 1, 2]` | ||
| 605 | 605 | ||
| 606 | 606 | Otherwise, the value of `options.stdio` is an array where each index corresponds | |
| 607 | 607 | to an fd in the child. The fds 0, 1, and 2 correspond to stdin, stdout, | |
| 608 | 608 | and stderr, respectively. Additional fds can be specified to create additional | |
| 609 | 609 | pipes between the parent and child. The value is one of the following: | |
| 610 | 610 | ||
| 611 | - 1. `'pipe'` - Create a pipe between the child process and the parent process. | ||
| 611 | + 1. `'pipe'`: Create a pipe between the child process and the parent process. | ||
| 612 | 612 | The parent end of the pipe is exposed to the parent as a property on the | |
| 613 | 613 | `child_process` object as [`subprocess.stdio[fd]`][`subprocess.stdio`]. Pipes | |
| 614 | - created for fds 0 - 2 are also available as [`subprocess.stdin`][], | ||
| 614 | + created for fds 0, 1, and 2 are also available as [`subprocess.stdin`][], | ||
| 615 | 615 | [`subprocess.stdout`][] and [`subprocess.stderr`][], respectively. | |
| 616 | - 2. `'ipc'` - Create an IPC channel for passing messages/file descriptors | ||
| 616 | + 2. `'ipc'`: Create an IPC channel for passing messages/file descriptors | ||
| 617 | 617 | between parent and child. A [`ChildProcess`][] may have at most one IPC | |
| 618 | 618 | stdio file descriptor. Setting this option enables the | |
| 619 | 619 | [`subprocess.send()`][] method. If the child is a Node.js process, the | |
@@ -624,25 +624,25 @@ pipes between the parent and child. The value is one of the following: | |||
| 624 | 624 | Accessing the IPC channel fd in any way other than [`process.send()`][] | |
| 625 | 625 | or using the IPC channel with a child process that is not a Node.js instance | |
| 626 | 626 | is not supported. | |
| 627 | - 3. `'ignore'` - Instructs Node.js to ignore the fd in the child. While Node.js | ||
| 628 | - will always open fds 0 - 2 for the processes it spawns, setting the fd to | ||
| 629 | - `'ignore'` will cause Node.js to open `/dev/null` and attach it to the | ||
| 627 | + 3. `'ignore'`: Instructs Node.js to ignore the fd in the child. While Node.js | ||
| 628 | + will always open fds 0, 1, and 2 for the processes it spawns, setting the fd | ||
| 629 | + to `'ignore'` will cause Node.js to open `/dev/null` and attach it to the | ||
| 630 | 630 | child's fd. | |
| 631 | - 4. `'inherit'` - Pass through the corresponding stdio stream to/from the | ||
| 631 | + 4. `'inherit'`: Pass through the corresponding stdio stream to/from the | ||
| 632 | 632 | parent process. In the first three positions, this is equivalent to | |
| 633 | 633 | `process.stdin`, `process.stdout`, and `process.stderr`, respectively. In | |
| 634 | 634 | any other position, equivalent to `'ignore'`. | |
| 635 | - 5. {Stream} object - Share a readable or writable stream that refers to a tty, | ||
| 635 | + 5. {Stream} object: Share a readable or writable stream that refers to a tty, | ||
| 636 | 636 | file, socket, or a pipe with the child process. The stream's underlying | |
| 637 | 637 | file descriptor is duplicated in the child process to the fd that | |
| 638 | 638 | corresponds to the index in the `stdio` array. The stream must have an | |
| 639 | 639 | underlying descriptor (file streams do not until the `'open'` event has | |
| 640 | 640 | occurred). | |
| 641 | - 6. Positive integer - The integer value is interpreted as a file descriptor | ||
| 641 | + 6. Positive integer: The integer value is interpreted as a file descriptor | ||
| 642 | 642 | that is currently open in the parent process. It is shared with the child | |
| 643 | 643 | process, similar to how {Stream} objects can be shared. Passing sockets | |
| 644 | 644 | is not supported on Windows. | |
| 645 | - 7. `null`, `undefined` - Use default value. For stdio fds 0, 1, and 2 (in other | ||
| 645 | + 7. `null`, `undefined`: Use default value. For stdio fds 0, 1, and 2 (in other | ||
| 646 | 646 | words, stdin, stdout, and stderr) a pipe is created. For fd 3 and up, the | |
| 647 | 647 | default is `'ignore'`. | |
| 648 | 648 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -39,7 +39,7 @@ For example, `--pending-deprecation` is equivalent to `--pending_deprecation`. | |||
| 39 | 39 | added: v8.0.0 | |
| 40 | 40 | --> | |
| 41 | 41 | ||
| 42 | - Alias for stdin, analogous to the use of - in other command line utilities, | ||
| 42 | + Alias for stdin. Analogous to the use of `-` in other command line utilities, | ||
| 43 | 43 | meaning that the script will be read from stdin, and the rest of the options | |
| 44 | 44 | are passed to that script. | |
| 45 | 45 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1417,15 +1417,15 @@ If `privateKey` is not a [`KeyObject`][], this function behaves as if | |||
| 1417 | 1417 | `privateKey` had been passed to [`crypto.createPrivateKey()`][]. If it is an | |
| 1418 | 1418 | object, the following additional properties can be passed: | |
| 1419 | 1419 | ||
| 1420 | - * `padding`: {integer} - Optional padding value for RSA, one of the following: | ||
| 1420 | + * `padding` {integer} Optional padding value for RSA, one of the following: | ||
| 1421 | 1421 | * `crypto.constants.RSA_PKCS1_PADDING` (default) | |
| 1422 | 1422 | * `crypto.constants.RSA_PKCS1_PSS_PADDING` | |
| 1423 | 1423 | ||
| 1424 | 1424 | `RSA_PKCS1_PSS_PADDING` will use MGF1 with the same hash function | |
| 1425 | 1425 | used to sign the message as specified in section 3.1 of [RFC 4055][], unless | |
| 1426 | 1426 | an MGF1 hash function has been specified as part of the key in compliance with | |
| 1427 | 1427 | section 3.3 of [RFC 4055][]. | |
| 1428 | - * `saltLength`: {integer} - salt length for when padding is | ||
| 1428 | + * `saltLength` {integer} Salt length for when padding is | ||
| 1429 | 1429 | `RSA_PKCS1_PSS_PADDING`. The special value | |
| 1430 | 1430 | `crypto.constants.RSA_PSS_SALTLEN_DIGEST` sets the salt length to the digest | |
| 1431 | 1431 | size, `crypto.constants.RSA_PSS_SALTLEN_MAX_SIGN` (default) sets it to the | |
@@ -1526,15 +1526,15 @@ If `object` is not a [`KeyObject`][], this function behaves as if | |||
| 1526 | 1526 | `object` had been passed to [`crypto.createPublicKey()`][]. If it is an | |
| 1527 | 1527 | object, the following additional properties can be passed: | |
| 1528 | 1528 | ||
| 1529 | - * `padding`: {integer} - Optional padding value for RSA, one of the following: | ||
| 1529 | + * `padding` {integer} Optional padding value for RSA, one of the following: | ||
| 1530 | 1530 | * `crypto.constants.RSA_PKCS1_PADDING` (default) | |
| 1531 | 1531 | * `crypto.constants.RSA_PKCS1_PSS_PADDING` | |
| 1532 | 1532 | ||
| 1533 | 1533 | `RSA_PKCS1_PSS_PADDING` will use MGF1 with the same hash function | |
| 1534 | 1534 | used to verify the message as specified in section 3.1 of [RFC 4055][], unless | |
| 1535 | 1535 | an MGF1 hash function has been specified as part of the key in compliance with | |
| 1536 | 1536 | section 3.3 of [RFC 4055][]. | |
| 1537 | - * `saltLength`: {integer} - salt length for when padding is | ||
| 1537 | + * `saltLength` {integer} Salt length for when padding is | ||
| 1538 | 1538 | `RSA_PKCS1_PSS_PADDING`. The special value | |
| 1539 | 1539 | `crypto.constants.RSA_PSS_SALTLEN_DIGEST` sets the salt length to the digest | |
| 1540 | 1540 | size, `crypto.constants.RSA_PSS_SALTLEN_AUTO` (default) causes it to be | |
@@ -2891,13 +2891,13 @@ If `key` is not a [`KeyObject`][], this function behaves as if `key` had been | |||
| 2891 | 2891 | passed to [`crypto.createPrivateKey()`][]. If it is an object, the following | |
| 2892 | 2892 | additional properties can be passed: | |
| 2893 | 2893 | ||
| 2894 | - * `padding`: {integer} - Optional padding value for RSA, one of the following: | ||
| 2894 | + * `padding` {integer} Optional padding value for RSA, one of the following: | ||
| 2895 | 2895 | * `crypto.constants.RSA_PKCS1_PADDING` (default) | |
| 2896 | 2896 | * `crypto.constants.RSA_PKCS1_PSS_PADDING` | |
| 2897 | 2897 | ||
| 2898 | 2898 | `RSA_PKCS1_PSS_PADDING` will use MGF1 with the same hash function | |
| 2899 | 2899 | used to sign the message as specified in section 3.1 of [RFC 4055][]. | |
| 2900 | - * `saltLength`: {integer} - salt length for when padding is | ||
| 2900 | + * `saltLength` {integer} Salt length for when padding is | ||
| 2901 | 2901 | `RSA_PKCS1_PSS_PADDING`. The special value | |
| 2902 | 2902 | `crypto.constants.RSA_PSS_SALTLEN_DIGEST` sets the salt length to the digest | |
| 2903 | 2903 | size, `crypto.constants.RSA_PSS_SALTLEN_MAX_SIGN` (default) sets it to the | |
@@ -2944,13 +2944,13 @@ If `key` is not a [`KeyObject`][], this function behaves as if `key` had been | |||
| 2944 | 2944 | passed to [`crypto.createPublicKey()`][]. If it is an object, the following | |
| 2945 | 2945 | additional properties can be passed: | |
| 2946 | 2946 | ||
| 2947 | - * `padding`: {integer} - Optional padding value for RSA, one of the following: | ||
| 2947 | + * `padding` {integer} Optional padding value for RSA, one of the following: | ||
| 2948 | 2948 | * `crypto.constants.RSA_PKCS1_PADDING` (default) | |
| 2949 | 2949 | * `crypto.constants.RSA_PKCS1_PSS_PADDING` | |
| 2950 | 2950 | ||
| 2951 | 2951 | `RSA_PKCS1_PSS_PADDING` will use MGF1 with the same hash function | |
| 2952 | 2952 | used to sign the message as specified in section 3.1 of [RFC 4055][]. | |
| 2953 | - * `saltLength`: {integer} - salt length for when padding is | ||
| 2953 | + * `saltLength` {integer} Salt length for when padding is | ||
| 2954 | 2954 | `RSA_PKCS1_PSS_PADDING`. The special value | |
| 2955 | 2955 | `crypto.constants.RSA_PSS_SALTLEN_DIGEST` sets the salt length to the digest | |
| 2956 | 2956 | size, `crypto.constants.RSA_PSS_SALTLEN_MAX_SIGN` (default) sets it to the | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -104,21 +104,21 @@ To begin watching an expression, type `watch('my_expression')`. The command | |||
| 104 | 104 | ||
| 105 | 105 | ### Stepping | |
| 106 | 106 | ||
| 107 | - * `cont`, `c` - Continue execution | ||
| 108 | - * `next`, `n` - Step next | ||
| 109 | - * `step`, `s` - Step in | ||
| 110 | - * `out`, `o` - Step out | ||
| 111 | - * `pause` - Pause running code (like pause button in Developer Tools) | ||
| 107 | + * `cont`, `c`: Continue execution | ||
| 108 | + * `next`, `n`: Step next | ||
| 109 | + * `step`, `s`: Step in | ||
| 110 | + * `out`, `o`: Step out | ||
| 111 | + * `pause`: Pause running code (like pause button in Developer Tools) | ||
| 112 | 112 | ||
| 113 | 113 | ### Breakpoints | |
| 114 | 114 | ||
| 115 | - * `setBreakpoint()`, `sb()` - Set breakpoint on current line | ||
| 116 | - * `setBreakpoint(line)`, `sb(line)` - Set breakpoint on specific line | ||
| 117 | - * `setBreakpoint('fn()')`, `sb(...)` - Set breakpoint on a first statement in | ||
| 115 | + * `setBreakpoint()`, `sb()`: Set breakpoint on current line | ||
| 116 | + * `setBreakpoint(line)`, `sb(line)`: Set breakpoint on specific line | ||
| 117 | + * `setBreakpoint('fn()')`, `sb(...)`: Set breakpoint on a first statement in | ||
| 118 | 118 | functions body | |
| 119 | - * `setBreakpoint('script.js', 1)`, `sb(...)` - Set breakpoint on first line of | ||
| 119 | + * `setBreakpoint('script.js', 1)`, `sb(...)`: Set breakpoint on first line of | ||
| 120 | 120 | `script.js` | |
| 121 | - * `clearBreakpoint('script.js', 1)`, `cb(...)` - Clear breakpoint in `script.js` | ||
| 121 | + * `clearBreakpoint('script.js', 1)`, `cb(...)`: Clear breakpoint in `script.js` | ||
| 122 | 122 | on line 1 | |
| 123 | 123 | ||
| 124 | 124 | It is also possible to set a breakpoint in a file (module) that | |
@@ -147,26 +147,26 @@ debug> | |||
| 147 | 147 | ||
| 148 | 148 | ### Information | |
| 149 | 149 | ||
| 150 | - * `backtrace`, `bt` - Print backtrace of current execution frame | ||
| 151 | - * `list(5)` - List scripts source code with 5 line context (5 lines before and | ||
| 150 | + * `backtrace`, `bt`: Print backtrace of current execution frame | ||
| 151 | + * `list(5)`: List scripts source code with 5 line context (5 lines before and | ||
| 152 | 152 | after) | |
| 153 | - * `watch(expr)` - Add expression to watch list | ||
| 154 | - * `unwatch(expr)` - Remove expression from watch list | ||
| 155 | - * `watchers` - List all watchers and their values (automatically listed on each | ||
| 153 | + * `watch(expr)`: Add expression to watch list | ||
| 154 | + * `unwatch(expr)`: Remove expression from watch list | ||
| 155 | + * `watchers`: List all watchers and their values (automatically listed on each | ||
| 156 | 156 | breakpoint) | |
| 157 | - * `repl` - Open debugger's repl for evaluation in debugging script's context | ||
| 158 | - * `exec expr` - Execute an expression in debugging script's context | ||
| 157 | + * `repl`: Open debugger's repl for evaluation in debugging script's context | ||
| 158 | + * `exec expr`: Execute an expression in debugging script's context | ||
| 159 | 159 | ||
| 160 | 160 | ### Execution control | |
| 161 | 161 | ||
| 162 | - * `run` - Run script (automatically runs on debugger's start) | ||
| 163 | - * `restart` - Restart script | ||
| 164 | - * `kill` - Kill script | ||
| 162 | + * `run`: Run script (automatically runs on debugger's start) | ||
| 163 | + * `restart`: Restart script | ||
| 164 | + * `kill`: Kill script | ||
| 165 | 165 | ||
| 166 | 166 | ### Various | |
| 167 | 167 | ||
| 168 | - * `scripts` - List all loaded scripts | ||
| 169 | - * `version` - Display V8's version | ||
| 168 | + * `scripts`: List all loaded scripts | ||
| 169 | + * `version`: Display V8's version | ||
| 170 | 170 | ||
| 171 | 171 | ## Advanced Usage | |
| 172 | 172 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -141,17 +141,17 @@ API usability issues that can lead to accidental security issues. | |||
| 141 | 141 | As an alternative, use one of the following methods of constructing `Buffer` | |
| 142 | 142 | objects: | |
| 143 | 143 | ||
| 144 | - * [`Buffer.alloc(size[, fill[, encoding]])`][alloc] - Create a `Buffer` with | ||
| 144 | + * [`Buffer.alloc(size[, fill[, encoding]])`][alloc]: Create a `Buffer` with | ||
| 145 | 145 | *initialized* memory. | |
| 146 | - * [`Buffer.allocUnsafe(size)`][alloc_unsafe_size] - Create a `Buffer` with | ||
| 146 | + * [`Buffer.allocUnsafe(size)`][alloc_unsafe_size]: Create a `Buffer` with | ||
| 147 | 147 | *uninitialized* memory. | |
| 148 | - * [`Buffer.allocUnsafeSlow(size)`][] - Create a `Buffer` with *uninitialized* | ||
| 148 | + * [`Buffer.allocUnsafeSlow(size)`][]: Create a `Buffer` with *uninitialized* | ||
| 149 | 149 | memory. | |
| 150 | - * [`Buffer.from(array)`][] - Create a `Buffer` with a copy of `array` | ||
| 150 | + * [`Buffer.from(array)`][]: Create a `Buffer` with a copy of `array` | ||
| 151 | 151 | * [`Buffer.from(arrayBuffer[, byteOffset[, length]])`][from_arraybuffer] - | |
| 152 | 152 | Create a `Buffer` that wraps the given `arrayBuffer`. | |
| 153 | - * [`Buffer.from(buffer)`][] - Create a `Buffer` that copies `buffer`. | ||
| 154 | - * [`Buffer.from(string[, encoding])`][from_string_encoding] - Create a `Buffer` | ||
| 153 | + * [`Buffer.from(buffer)`][]: Create a `Buffer` that copies `buffer`. | ||
| 154 | + * [`Buffer.from(string[, encoding])`][from_string_encoding]: Create a `Buffer` | ||
| 155 | 155 | that copies `string`. | |
| 156 | 156 | ||
| 157 | 157 | Without `--pending-deprecation`, runtime warnings occur only for code not in | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -706,8 +706,8 @@ changes: | |||
| 706 | 706 | * `ipv6Only` {boolean} Setting `ipv6Only` to `true` will | |
| 707 | 707 | disable dual-stack support, i.e., binding to address `::` won't make | |
| 708 | 708 | `0.0.0.0` be bound. **Default:** `false`. | |
| 709 | - * `recvBufferSize` {number} - Sets the `SO_RCVBUF` socket value. | ||
| 710 | - * `sendBufferSize` {number} - Sets the `SO_SNDBUF` socket value. | ||
| 709 | + * `recvBufferSize` {number} Sets the `SO_RCVBUF` socket value. | ||
| 710 | + * `sendBufferSize` {number} Sets the `SO_SNDBUF` socket value. | ||
| 711 | 711 | * `lookup` {Function} Custom lookup function. **Default:** [`dns.lookup()`][]. | |
| 712 | 712 | * `callback` {Function} Attached as a listener for `'message'` events. Optional. | |
| 713 | 713 | * Returns: {dgram.Socket} | |
@@ -725,8 +725,8 @@ and port can be retrieved using [`socket.address().address`][] and | |||
| 725 | 725 | added: v0.1.99 | |
| 726 | 726 | --> | |
| 727 | 727 | ||
| 728 | - * `type` {string} - Either `'udp4'` or `'udp6'`. | ||
| 729 | - * `callback` {Function} - Attached as a listener to `'message'` events. | ||
| 728 | + * `type` {string} Either `'udp4'` or `'udp6'`. | ||
| 729 | + * `callback` {Function} Attached as a listener to `'message'` events. | ||
| 730 | 730 | * Returns: {dgram.Socket} | |
| 731 | 731 | ||
| 732 | 732 | Creates a `dgram.Socket` object of the specified `type`. | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -286,7 +286,7 @@ throw when an attempt is made to import them: | |||
| 286 | 286 | ||
| 287 | 287 | ```js | |
| 288 | 288 | import submodule from 'es-module-package/private-module.js'; | |
| 289 | - // Throws - Module not found | ||
| 289 | + // Throws ERR_MODULE_NOT_FOUND | ||
| 290 | 290 | ``` | |
| 291 | 291 | ||
| 292 | 292 | > Note: this is not a strong encapsulation as any private modules can still be | |
| Back | FazBrowse Home | New Git URL |
0 commit comments