mirror of
https://github.com/transloadit/uppy.git
synced 2026-07-20 16:53:33 +00:00
| Package | Version | Package | Version | | -------------------- | ------------ | -------------------- | ------------ | | @uppy/aws-s3 | 4.0.0-beta.4 | @uppy/status-bar | 4.0.0-beta.8 | | @uppy/companion | 5.0.0-beta.7 | @uppy/svelte | 4.0.0-beta.4 | | @uppy/compressor | 2.0.0-beta.8 | @uppy/tus | 4.0.0-beta.5 | | @uppy/core | 4.0.0-beta.8 | @uppy/utils | 6.0.0-beta.7 | | @uppy/dashboard | 4.0.0-beta.8 | @uppy/vue | 2.0.0-beta.3 | | @uppy/image-editor | 3.0.0-beta.5 | @uppy/webcam | 4.0.0-beta.7 | | @uppy/provider-views | 4.0.0-beta.6 | uppy | 4.0.0-beta.8 | - @uppy/core: resolve some (breaking) TODOs (Antoine du Hamel / #4824) - @uppy/companion: encode `uploadId` (Mikael Finstad / #5168) - @uppy/companion: bump `express-session` (Antoine du Hamel / #5177) - @uppy/companion: remove dependency on `express-request-id` (Antoine du Hamel / #5176) - @uppy/companion: bump prom to v15 (Antoine du Hamel / #5175) - docs: fix linter (Antoine du Hamel) - meta: remove `nodemon` from the deps (Antoine du Hamel / #5172) - docs: update `@uppy/aws-s3` docs (Antoine du Hamel / #5093) - meta: update more dependencies (Antoine du Hamel / #5171) - @uppy/companion: upgrade deps (Antoine du Hamel / #5119) |
||
|---|---|---|
| .. | ||
| src | ||
| .npmignore | ||
| CHANGELOG.md | ||
| LICENSE | ||
| package.json | ||
| README.md | ||
| tsconfig.build.json | ||
| tsconfig.json | ||
@uppy/compressor
The Compressor plugin for Uppy optimizes images (JPEG, PNG, WEBP), saving on average up to 60% in size (roughly 18 MB for 10 images). It uses Compressor.js.
Uppy is being developed by the folks at Transloadit, a versatile file encoding service.
Example
import Uppy from '@uppy/core'
import Compressor from '@uppy/compressor'
const uppy = new Uppy()
uppy.use(Compressor)
Installation
npm install @uppy/compressor
We recommend installing from yarn or npm, and then using a module bundler such as Parcel, Vite or Webpack.
Alternatively, you can also use this plugin in a pre-built bundle from
Transloadit’s CDN: Edgly. In that case Uppy will attach itself to the global
window.Uppy object. See the
main Uppy documentation for instructions.
Documentation
Documentation for this plugin can be found on the Uppy website.