Stack Exchange allows users that add an image to a post to enter an alt text. When uploading an image the following markdown is inserted:
[![enter image description here][1]][1]
[1]: https://i.sstatic.net/some-id.png
Recently the alt text feature has become more prominent with the following pop-up message below the editor when you add an image but do not modify the template text:
Image Alt Text
Images should have specific alt text briefly explaining what is shown. Use the square brackets immediately following the '!' for this (which may currently contain 'enter image description here').
In my answers I always add a screenshot of the result at the end. Almost all of my answers follow the following structure:
Text discussing the issue and the proposed solution, often with
inline code
or with one or moresmall code blocks
MWE:
full code of mwe
Result:
🖼️ (image with screenshot of result)occasionally some closing remarks after the screenshot
I never added an alt text before. Since the pop-up message was implemented I do change the alt text into screenshot of result
because that seems like a valid description of the image.
I do wonder however if this conforms to best practises. I have the following questions:
- Is the alt text
screenshot of result
sufficiently specific? If not, then what should it be instead? - What about the situation where two different options are presented in an answer, each with their own screenshot of the result?
- The WCAG defines some exceptions to the need for alternative text, that seem to be based on a consideration if the alt text is helpful for reading the page if the user is visually impaired. A screenshot does not provide any added value if a user is visually impaired, and an alternative text cannot convey the intention of "you can see here that the output addresses the issue that the question asked about". Therefore it seems superfluous to add an essentially empty placeholder text. Of course it is informative for a visually impaired user to know that the image can safely be skipped, but given the context of the answer this is probably already sufficiently clear. Does it still serve a purpose to add an alternative text for screenshots like this?