Is alt the same as alt=“”?

前端 未结 1 1956
一向
一向 2021-01-19 02:31

I\'m adding alt attributes to all my images to improve SEO/screen reader performance.

Per best practice, images that are purely aesthetic should have an

1条回答
  •  醉梦人生
    2021-01-19 03:30

    Yes, it's the same: https://www.w3.org/TR/html5/syntax.html#attributes-0

    Empty attribute syntax

    Just the attribute name. The value is implicitly the empty string.

    To me, that says that an attribute with no value is the same as having a value of empty string.

    This answer says the same.

    0 讨论(0)
提交回复
热议问题