Beside the filters provided by Liquid, Shopline added extra filters for you:

img_url

The image url filter provides a convenient way to resize your image, given the option with format: Width x Height Transform

Examples:

  • Rendering an image with max width of 300px and free on height, you can use 300x
{{ image.src | img_url: '300x' }}
  • Rendering an image with max height of 80px and free on width, you can use x80
{{ image.src | img_url: 'x80' }}
  • Rendering an image with max of both width and height in 500px box, use 500x500
{{ image.src | img_url: '500x500' }}
  • Rendering an image with centered crop in a 200px x 200px dimension, use 200x200f
{{ image.src | img_url: '200x200f' }}
  • Rendering an image with min of both width and height than 300px, use 300x300s
{{ image.src | img_url: '300x300s' }}