Title on QImg



  • On a QImg, I can see that we can set the ALT attribute for the image.

    Is there anyway to also set the TITLE attribute for the image?

    I know I could use a normal IMG tag rather than a QImg to get it … but I’d prefer to use a QImg so that I can take advantage of the loading spinner and placeholder …


  • Admin

    QImg does not render an <img> tag under the covers, so adding such props does not have any effect. The alt property is applied as aria-label attribute along with role="img" (accessibility work). QImg uses a <div> with backgroundImage CSS in order to be able to supply all its features.



  • @rstoenescu Thanks for clarifying why it’s not there … I understand.


Log in to reply