Twill image crops rendering
# ❓questions
e
Does the Twill image crop create new versions of the images in the dimensions we provided in the models..?
i
The crop ratios you provide in the model control which crops are available to manage in the CMS form field. From there, it saves the crop coordinates in database. On the rendering side, twill is meant to be used with a dynamic image rendering solution with an HTTP based API, like Glide (free and open source, by default in twill 3, already available in twill 2), Imgix, Twicpics, etc. When using the
->image('image-role', ['w' => 1000])
helper on a model or block, you'll get a url like this:
https://domain.com/img/random-string/image-filename.jpg?fit=crop&rect=x,y,w,h&w=1000
. From there you can implement all responsive images approaches including art directed responsive where you change image ratios depending on the device width. If you are looking to automate all of that without having to learn much, you can try #873445927740903475 (area17/twill-image)
e
Thanks! It's fixed