@@ -378,6 +378,9 @@ console.log(buf2.toString());
378378```
379379
380380### Class Method: Buffer.alloc(size[ , fill[ , encoding]] )
381+ <!-- YAML
382+ added: v4.5.0
383+ -->
381384
382385* ` size ` {Number}
383386* ` fill ` {Value} Default: ` undefined `
@@ -422,6 +425,9 @@ contents will *never contain sensitive data*.
422425A ` TypeError ` will be thrown if ` size ` is not a number.
423426
424427### Class Method: Buffer.allocUnsafe(size)
428+ <!-- YAML
429+ added: v4.5.0
430+ -->
425431
426432* ` size ` {Number}
427433
@@ -464,6 +470,9 @@ difference is subtle but can be important when an application requires the
464470additional performance that ` Buffer.allocUnsafe(size) ` provides.
465471
466472### Class Method: Buffer.allocUnsafeSlow(size)
473+ <!-- YAML
474+ added: v4.5.0
475+ -->
467476
468477* ` size ` {Number}
469478
@@ -531,6 +540,9 @@ console.log(`${str}: ${str.length} characters, ` +
531540```
532541
533542### Class Method: Buffer.compare(buf1, buf2)
543+ <!-- YAML
544+ added: v0.11.13
545+ -->
534546
535547* ` buf1 ` {Buffer}
536548* ` buf2 ` {Buffer}
@@ -545,6 +557,9 @@ arr.sort(Buffer.compare);
545557```
546558
547559### Class Method: Buffer.concat(list[ , totalLength] )
560+ <!-- YAML
561+ added: v0.7.11
562+ -->
548563
549564* ` list ` {Array} List of Buffer objects to concat
550565* ` totalLength ` {Number} Total length of the Buffers in the list when concatenated
@@ -579,6 +594,9 @@ console.log(bufA.length);
579594```
580595
581596### Class Method: Buffer.from(array)
597+ <!-- YAML
598+ added: v3.0.0
599+ -->
582600
583601* ` array ` {Array}
584602
@@ -593,6 +611,9 @@ const buf = Buffer.from([0x62,0x75,0x66,0x66,0x65,0x72]);
593611A ` TypeError ` will be thrown if ` array ` is not an ` Array ` .
594612
595613### Class Method: Buffer.from(arrayBuffer)
614+ <!-- YAML
615+ added: v4.5.0
616+ -->
596617
597618* ` arrayBuffer ` {ArrayBuffer} The ` .buffer ` property of a ` TypedArray ` or
598619 a ` new ArrayBuffer() `
@@ -621,6 +642,9 @@ console.log(buf);
621642A ` TypeError ` will be thrown if ` arrayBuffer ` is not an ` ArrayBuffer ` .
622643
623644### Class Method: Buffer.from(buffer)
645+ <!-- YAML
646+ added: v3.0.0
647+ -->
624648
625649* ` buffer ` {Buffer}
626650
@@ -640,6 +664,9 @@ console.log(buf2.toString());
640664A ` TypeError ` will be thrown if ` buffer ` is not a ` Buffer ` .
641665
642666### Class Method: Buffer.from(str[ , encoding] )
667+ <!-- YAML
668+ added: v4.5.0
669+ -->
643670
644671* ` str ` {String} String to encode.
645672* ` encoding ` {String} Encoding to use, Default: ` 'utf8' `
@@ -670,6 +697,9 @@ A `TypeError` will be thrown if `str` is not a string.
670697Returns 'true' if ` obj ` is a Buffer.
671698
672699### Class Method: Buffer.isEncoding(encoding)
700+ <!-- YAML
701+ added: v0.9.1
702+ -->
673703
674704* ` encoding ` {String} The encoding string to test
675705* Return: {Boolean}
@@ -678,9 +708,10 @@ Returns true if the `encoding` is a valid encoding argument, or false
678708otherwise.
679709
680710### buf[ index]
681-
682- <!-- type=property-->
683- <!-- name=[index]-->
711+ <!-- YAML
712+ type: property
713+ name: [index]
714+ -->
684715
685716The index operator ` [index] ` can be used to get and set the octet at position
686717` index ` in the Buffer. The values refer to individual bytes, so the legal value
@@ -701,6 +732,9 @@ console.log(buf.toString('ascii'));
701732```
702733
703734### buf.compare(otherBuffer)
735+ <!-- YAML
736+ added: v0.11.13
737+ -->
704738
705739* ` otherBuffer ` {Buffer}
706740* Return: {Number}
@@ -777,6 +811,9 @@ console.log(buf.toString());
777811```
778812
779813### buf.entries()
814+ <!-- YAML
815+ added: v1.1.0
816+ -->
780817
781818* Return: {Iterator}
782819
@@ -798,6 +835,9 @@ for (var pair of buf.entries()) {
798835```
799836
800837### buf.equals(otherBuffer)
838+ <!-- YAML
839+ added: v1.0.0
840+ -->
801841
802842* ` otherBuffer ` {Buffer}
803843* Return: {Boolean}
@@ -817,6 +857,9 @@ console.log(buf1.equals(buf3));
817857```
818858
819859### buf.fill(value[ , offset[ , end]] )
860+ <!-- YAML
861+ added: v0.5.0
862+ -->
820863
821864* ` value ` {String|Number}
822865* ` offset ` {Number} Default: 0
@@ -834,6 +877,9 @@ console.log(b.toString());
834877```
835878
836879### buf.indexOf(value[ , byteOffset] [ , encoding ] )
880+ <!-- YAML
881+ added: v1.5.0
882+ -->
837883
838884* ` value ` {String|Buffer|Number}
839885* ` byteOffset ` {Number} Default: 0
@@ -904,6 +950,9 @@ buf.includes('this', 4);
904950```
905951
906952### buf.keys()
953+ <!-- YAML
954+ added: v1.1.0
955+ -->
907956
908957* Return: {Iterator}
909958
@@ -1090,6 +1139,9 @@ buf.readInt32LE(1);
10901139
10911140### buf.readIntBE(offset, byteLength[ , noAssert] )
10921141### buf.readIntLE(offset, byteLength[ , noAssert] )
1142+ <!-- YAML
1143+ added: v1.0.0
1144+ -->
10931145
10941146* ` offset ` {Number} ` 0 <= offset <= buf.length - byteLength `
10951147* ` byteLength ` {Number} ` 0 < byteLength <= 6 `
@@ -1194,6 +1246,9 @@ console.log(buf.readUInt32LE(0));
11941246
11951247### buf.readUIntBE(offset, byteLength[ , noAssert] )
11961248### buf.readUIntLE(offset, byteLength[ , noAssert] )
1249+ <!-- YAML
1250+ added: v1.0.0
1251+ -->
11971252
11981253* ` offset ` {Number} ` 0 <= offset <= buf.length - byteLength `
11991254* ` byteLength ` {Number} ` 0 < byteLength <= 6 `
@@ -1288,6 +1343,9 @@ buf.toString(undefined,0,5);
12881343```
12891344
12901345### buf.toJSON()
1346+ <!-- YAML
1347+ added: v0.9.2
1348+ -->
12911349
12921350* Return: {Object}
12931351
@@ -1314,6 +1372,9 @@ console.log(copy.toString());
13141372```
13151373
13161374### buf.values()
1375+ <!-- YAML
1376+ added: v1.1.0
1377+ -->
13171378
13181379* Return: {Iterator}
13191380
@@ -1516,6 +1577,9 @@ console.log(buf);
15161577
15171578### buf.writeIntBE(value, offset, byteLength[ , noAssert] )
15181579### buf.writeIntLE(value, offset, byteLength[ , noAssert] )
1580+ <!-- YAML
1581+ added: v1.0.0
1582+ -->
15191583
15201584* ` value ` {Number} Bytes to be written to Buffer
15211585* ` offset ` {Number} ` 0 <= offset <= buf.length - byteLength `
0 commit comments