Closed janko closed 2 years ago
Hi @janko-m , thank you very much for the interesting suggestion. We have added this to our road-map. We will update on the ETA once this is determined. Thanks again!
Cool, exactly what I had an issue with! Thanks @janko-m :)
Hi @janko, @Frexuz - I saw this thread was open for a while so I'm revisiting it. When using resizing transformations in URLs, such as width and/or height, you can use those without a crop mode and it will default to scale
on the backend. That said, via the SDKs, crop mode is a mandatory parameter otherwise the resizing parameters like width/height won't be set as you've seen. This is documented under the Note
section just below this section of the documentation - https://cloudinary.com/documentation/resizing_and_cropping#resize_and_crop_modes. At the moment, there aren't any plans to change this behaviour, so I'll close this thread, however, if that changes we will be sure to update it here too. 🙏
Thank you for an awesome service and a nice wrapper gem.
While playing with URLs I noticed that if I don't pass in
:crop
, the:width
and:height
options will be ignored. That surprised me, because I didn't know that:crop
was mandatory, I only realized it through some source code diving.My proposal is to instead make
:crop
default to "fit", or whatever value you find to be a good default. It could be on the gem level or Cloudinary level, I don't know which one is better.If the
:crop
option really must be mandatory, it would be good to at least add a warning when:crop
is not passed in that:width
and:height
will be ignored.