We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
In the 'srcset' and 'sizes' attribute of the img tag can contain float numbers.
This {{ picture_size.size.0}}w output the pixel size as 1366.0w which triggers this warning in chrome:
Failed parsing 'srcset' attribute value since its 'w' descriptor is invalid.
I solved this by using a float format filter to remove the decimal point:
{{ picture_size.size.0 | floatformat:"0" }}w
The text was updated successfully, but these errors were encountered:
Hello @TLuesebrinck ! Thanks very much for the suggestion! Would you be interested in creating a pull request with a fix?
Sorry, something went wrong.
No branches or pull requests
In the 'srcset' and 'sizes' attribute of the img tag can contain float numbers.
This {{ picture_size.size.0}}w output the pixel size as 1366.0w which triggers this warning in chrome:
Failed parsing 'srcset' attribute value since its 'w' descriptor is invalid.
I solved this by using a float format filter to remove the decimal point:
{{ picture_size.size.0 | floatformat:"0" }}w
The text was updated successfully, but these errors were encountered: