Node.js StringDecoder
The Node.js StringDecoder is used to decode buffer into string. It is similar to buffer.toString() but provides extra support to UTF. You need to use require(‘string_decoder’) to use StringDecoder module. Node.js StringDecoder Methods StringDecoder class has two methods only. Method Description decoder.write(buffer) It is used to return the decoded string. decoder.end() It is used to […]