Skip to content

Commit 3034038

Browse files
vsemozhetbytFishrock123
authored andcommitted
doc: add a variable declaration in the buffer.md
PR-URL: #9795 Reviewed-By: Sam Roberts <[email protected]> Reviewed-By: Roman Reiss <[email protected]> Reviewed-By: Anna Henningsen <[email protected]>
1 parent 778e5f7 commit 3034038

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

doc/api/buffer.md

+2
Original file line numberDiff line numberDiff line change
@@ -2328,6 +2328,8 @@ The transcoding process will use substitution characters if a given byte
23282328
sequence cannot be adequately represented in the target encoding. For instance:
23292329

23302330
```js
2331+
const buffer = require('buffer');
2332+
23312333
const newBuf = buffer.transcode(Buffer.from(''), 'utf8', 'ascii');
23322334
console.log(newBuf.toString('ascii'));
23332335
// Prints: '?'

0 commit comments

Comments
 (0)