You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When you call getResizedImage() within a Twig file, the image tag is rendered with width and height attributes.
This is almost always handy to avoid janky page loading, but in some cases (such as when you're doing something responsive) you don't want this as it's impossible(?) to override with CSS.
You can pass an associative array of attributes as the 4th parameter for this function, but passing width or height would result in two width or height parameters.
Update the code to watch for these attributes, and if they are defined with a value of null, perhaps, don't render the attributes.
The text was updated successfully, but these errors were encountered:
When you call
getResizedImage()
within a Twig file, the image tag is rendered withwidth
andheight
attributes.This is almost always handy to avoid janky page loading, but in some cases (such as when you're doing something responsive) you don't want this as it's impossible(?) to override with CSS.
You can pass an associative array of attributes as the 4th parameter for this function, but passing
width
orheight
would result in twowidth
orheight
parameters.Update the code to watch for these attributes, and if they are defined with a value of
null
, perhaps, don't render the attributes.The text was updated successfully, but these errors were encountered: