We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 25226ce commit d5b1a4bCopy full SHA for d5b1a4b
doc/api/buffer.md
@@ -618,6 +618,10 @@ Returns the actual byte length of a string. This is not the same as
618
[`String.prototype.length`] since that returns the number of *characters* in
619
a string.
620
621
+*Note* that for `'base64'` and `'hex'`, this function assumes valid input. For
622
+strings that contain non-Base64/Hex-encoded data (e.g. whitespace), the return
623
+value might be greater than the length of a `Buffer` created from the string.
624
+
625
Example:
626
627
```js
0 commit comments