I'm wrapping data to a Node.js WebSocket server in JSON. I'm trying to log the contents of the JSON object server side, but Regardless of the method I try, Node just logs object Object
I have tried
console.log(message.data)
console.log(util.inspect(message.data, {showHidden: true, depth: null}));
console.log(JSON.stringify(message.data));
Why would Node.js log object Object ? is the JSON malformed?
I'm sending VERY simple JSON objects from the client. Things like
ws.send({'a': 0, 'b': 1});