{"library":"upng-js","type":"library","category":null,"description":"UPNG.js is a small, fast, and advanced PNG/APNG encoder and decoder, used as the core PNG engine in the Photopea image editor (current stable: 2.1.0). It supports encoding single PNGs and APNG animations with optional lossy color quantization (k-means) for file size reduction, decoding all color types, bit depths (1–16), interlaced images, and additional PNG chunks. Key differentiators include handling PNGs that other libraries cannot open, lossy compression akin to TinyPNG, and a lightweight footprint.","language":"javascript","status":"active","version":"2.1.0","tags":["javascript","png","apng","image","conversion"],"last_verified":"Thu Jun 04","install":[{"cmd":"npm install upng-js","imports":["import UPNG from 'upng-js'","import UPNG from 'upng-js'; UPNG.encode(imgs, w, h, cnum, dels)","import UPNG from 'upng-js'; UPNG.decode(buffer)","import UPNG from 'upng-js'; UPNG.toRGBA8(img)"]},{"cmd":"yarn add upng-js","imports":[]},{"cmd":"pnpm add upng-js","imports":[]}],"homepage":"https://github.com/photopea/UPNG.js","github":"https://github.com/photopea/UPNG.js","docs":null,"changelog":null,"pypi":null,"npm":"upng-js","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":null}