{"library":"jpeg-js","type":"library","category":null,"description":"jpeg-js is a pure JavaScript library designed for encoding and decoding JPEG images without relying on native binaries or external dependencies. This makes it suitable for various JavaScript environments, including Node.js and browsers (browser support was explicitly added in v0.4.0). It offers synchronous APIs for converting raw image data to the JPEG format and vice-versa, providing direct control over image processing. The current stable version is 0.4.4, released in June 2022. The project has a relatively slow release cadence, with the most recent updates focusing on bug fixes and minor feature enhancements. Its primary differentiating factor is its complete JavaScript implementation, beneficial for environments with strict dependency constraints or where native modules are problematic. However, a significant trade-off is its performance: it is a CPU-blocking library and is considerably slower than native alternatives like `sharp` or browser-native `Canvas API`, which is a crucial consideration for any performance-sensitive application.","language":"javascript","status":"active","version":"0.4.4","tags":["javascript","jpeg","jpg","encoder","decoder","codec","image","js"],"last_verified":"Wed May 27","install":[{"cmd":"npm install jpeg-js","imports":["import * as jpeg from 'jpeg-js';","const jpeg = require('jpeg-js');\nconst decoded = jpeg.decode(buffer);","const jpeg = require('jpeg-js');\nconst encoded = jpeg.encode(imageData, quality);"]},{"cmd":"yarn add jpeg-js","imports":[]},{"cmd":"pnpm add jpeg-js","imports":[]}],"homepage":null,"github":"https://github.com/eugeneware/jpeg-js","docs":null,"changelog":null,"pypi":null,"npm":"https://www.npmjs.com/package/jpeg-js","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":{"summary":{"python_range":"18–22","success_rate":0,"avg_install_s":null,"avg_import_s":null,"wheel_type":null},"url":"https://checklist.day/v1/registry/jpeg-js/compatibility"}}