bellroy / elm-imgix / ImgIX.Format

The format parameters give you control over the output properties of your image across several aspects.

ImgIX documentation for Format


type alias Format =
{ outputQuality : Maybe Basics.Int
, useLossless : Maybe Basics.Bool 
}

The Format type

empty : Format

Output Quality

Controls the output quality of lossy file formats (jpg, pjpg, webp, or jxr).

Valid values are in the range 0 – 100 and the default is 75. Quality can often be set much lower than the default, especially when serving high-DPR images.

q : Basics.Int -> Format -> Format

Set the output quality of lossy file formats.

Lossless

The lossless parameter enables delivery of lossless images in formats that support lossless compression (JPEG XR and WEBP).

Valid values are 1/true and 0/false. When unset or set to an invalid value, lossless defaults to false.

lossless : Basics.Bool -> Format -> Format

Set to enable/disable the delivery of lossless images in formats that support lossless compression (JPEG XR and WEBP).

Applying

toQueryParameters : Format -> List Url.Builder.QueryParameter

Takes format operations and turns them to a list of URL query parameters that ImgIX understands