Skip to content

Consider adding back djlint (html linter) rule H006 (<img> tags need height and width attributes) #1104

Open
@TrialDragon

Description

@TrialDragon

I disagree on the disabling of one of those linter rules (H006) since I left it in for a reason (it's considered best practice to define height and width attributes on tags consisting of the size of the image being used, or imo when we're dealing with template then base size desired for layout unless we have a way to get the size of each image. Otherwise the browser would have to reflow and repaint the page which is a minor performance cost to account for variable size which also looks ugly since it causes images to pop in out of nowhere iirc).

TrialDragon (me) on Discord

As far as I know, this info is up to date, but perhaps I'm wrong about all of this. Thoughts on re-adding this rule?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions