1

I'm pulling a png image string from s3 that looks like

�PNG\r\n' + '\x1A\n' + '\x00\x00\x00\rIHDR\x00\x00\x02\x00\x00\x00\x02\x00\b\x02\x00\x00\x00...

I'm trying to manipulate this image with Jimp

  const buffer = Buffer.from(imageString);
  const jimpImage = await Jimp.read(buffer.toString());

But I'm getting this error

The argument 'path' must be a string or Uint8Array without null bytes. Received '�PNG\r\n'...
Shakil
  • 11
  • 1

0 Answers0