Well, I see now that you are using a hashmap module. You are either know what you are doing, and using it for a good reason, or maybe you came from Java and then you just better be using JS Objects, which are extremely fast and optimized. You can also use native Maps https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map
The rest is about objects, but with plain objects you probably can just send them throw web sockets, without stringifing (most likely socket library will be stringifying them on server and parsing them on client internally).
You might try to stringify it in node.js and parse on the client. Like so
io.sockets.emit('state', JSON.stringify(myHashmap));
and then on the client parse it
const data = JSON.parse(payload)
I guess you are talking about js objects like const myHashmap = {}; ?