Buffer implementation, in browsers use buffer
npm package
and import it from buffer/
, in Node.js simply pass Buffer
.
[customDeserializers] - optional arguments if you need to unserialize custom data types,
Buffer to unserialize
unserialized data
Unserialize data from a Buffer serialized with serializeToBuffer, useful when working with web sockets or other binary protocols. Make sure to understand how deserialize works before using this function.