Skip to content
@drupflare/spool v1.0.0 GitHub
    Preparing search index...

    Function tinyimgEncoder

    • An ImageEncoder over tinyimg. It passes fit: 'scale-down' when a width is set, which keeps tinyimg from upscaling, passes lossless and budgetMs when the proxy sets them, and returns the bytes of the result. A module whose version is older than TINYIMG_MIN_VERSION is refused with a ProtocolError, since converting an EXIF-rotated JPEG with it would serve the picture sideways. A module that reports no version is accepted.

      Type Parameters

      • M

      Parameters

      Returns ImageEncoder