@usecds/imaging
v0.2.0
Published
Image processing that complements CDS: focal-point crops and sizes per breakpoint, rendered with sharp
Readme
@usecds/imaging
Image processing that complements CDS. CDS carries the original media files, their focal points and the sizes a target declares per breakpoint; this package renders the variants with sharp, so a site can prerender every image at build time and serve it as a static file.
render: one variant (crop to an aspect ratio around the focal points, or fit; format, quality, lossless)responsiveSizes,cropRegion,variantKey,canonicalOptions,parseAspect,isVectorVariantCache: renders a variant on first request and keeps it on disk
npm install @usecds/imagingIt is not part of CDS core: rendered variants never enter a release. Documentation: docs/imaging.md.
