Open yangdan8 opened 4 years ago
The following code will lose the 10 characters "0123456789": var topic ='xxx'; var data = {a:5}; stompServer.send( topic, {}, JSON.stringify({ topic, data, }) + '0123456789', );
var topic ='xxx'; var data = {a:5}; stompServer.send( topic, {}, JSON.stringify({ topic, data, }) + '0123456789', );
try to use for third argument Buffer.from(JSON.stringify({ topic, data, }) + '0123456789', 'utf-8').
The following code will lose the 10 characters "0123456789":
var topic ='xxx'; var data = {a:5}; stompServer.send( topic, {}, JSON.stringify({ topic, data, }) + '0123456789', );