Node.js Buffer toJSON() convert buffer content to String

Description

Node.js Buffer toJSON() convert buffer content to String


var buf = new Buffer.from('Simply Easy Learning');
var json = buf.toJSON(buf);

console.log(json);//w ww  .  j  a  v a 2s . co m



PreviousNext

Related