Convert a buffer to and from png image data.
npm install buffer-image
const bufferImage = require("buffer-image");
(async () => {
const image = await bufferImage(Buffer.from("Hello World"));
const result = await bufferImage.from(image)
console.log(result.toString())
//=> "Hello World"
})()
Convert a buffer to a png buffer.
Convert a png buffer to a buffer.
Type: string
The buffer to convert.