36

I strongly agree with the answers in, "Is using 'header' markdown okay in answers?" I use headings quite frequently in my answers, but generally only an H4, and only when there are multiple "sections" to separate.

But are there any general rules that allow or disallow formatting that is solely designed to make a question or answer stand out (a.k.a. "attention grabbing")?

I see "Should unnecessary formatting (that serves to draw attention) be considered an antipattern?", to which I like @Lundin's answer:

So this is to be regarded as "fluff", for which we already have a policy: Should I remove 'fluff' when editing questions?

Ok, great. So I've been doing the right thing by removing fluff in edits. But what if a user rejects those edits and returns the "fluff" (a.k.a. in this case, attention grabbing).

Ultimately, I'm referring to this answer, where the user has rejected my edits to remove the (IMO) unnecessary formatting (as well as updated info, but that's completely their right).

In the original version, it was an H1 with a series of emojis, and no subheadings which would even have warranted an H1. I edited it down to an H4, removed the emojis, and added another H4 for "Notes". There's really no structural reason for it to even have an H4 "title/heading", since answers aren't supposed to have titles. A heading, if needed should introduce a distinct section of the answer, not be a replacement for a title.

But the user has rejected the edits, returning it to H1 + Emojis (saying they preferred it), and then even made the "Notes" an H2. I could see an H3 and H4 at best (but still "fluff"), but the H1 with emojis seems completely (to be polite) unnecessary.

Not to mention that the entire question is way off-topic anyway, but, well, I know how to approach that. I did flag it when I was sub-3k rep, and now I've cast a Close vote on it. And yes, I was guilty of lobbing an answer on it after nothing happened with my Close flag a couple of months ago.

But what's the right way to handle "attention grabbing formatting", when the user declines to "play nice" and accept the edit?

  • Leave it be, as there are no rules against it?
  • Flag it for a moderator? But what "rules" would I reference?
  • Bring it to Meta like this?
  • Or something else?

Related - As @jonrsharpe points out in the comments, this seems to be a recurring problem for this user in posting this answer across multiple (duplicate, off-topic) questions.

Related - Are comments by a user on the main question attempting to promote their answer (as I just noticed was also done by this user for their answer) acceptable? Or should that be flagged for removal?

Related - For reference, the editing-help mentions H1/H2 with no guidance on where they are actually appropriate.

14
  • 16
    They're also busy spamming the same answer (albeit with slightly less aggravating formatting) across a bunch of other questions: stackoverflow.com/questions/61110603/…, stackoverflow.com/questions/67608349/…
    – jonrsharpe
    Oct 6, 2021 at 22:56
  • @jonrsharpe Right - Still H1's on them, but yes, at least not the aggravating emojis. To be fair the accepted answer on the first one also uses an H1, which this user seems to have copied (with the TL;DR moniker) onto their next answer. All of these are, again, IMHO off-topic. But the poster of the second one convinced folks to re-open with the "WSL is a programming tool" argument, which I disagreed with. But mainly here, I'm more concerned with how to handle the rejected/reversed edits to attempt to fix the problem. Oct 6, 2021 at 23:01
  • 7
    Note that the quote formatting is also being misused here: Those aren't actually direct quotes from the sources. Also, the "*just works*™" (that gets used twice) is very..."market-y" for lack of a better term. I'd also argue that emphasis is being overused in general; I don't think software names need to be bold every time they appear in text. All that said, I'll let an actual moderator chime in on whether this rises to the level of being flag-worthy.
    – BSMP
    Oct 7, 2021 at 1:54
  • 11
    Concerning H1 vs. H4: I don't think you should choose a particular heading level just to get a particular font size. Generally, the levels represent a tree structure (from what you can generate a TOC for example). IMHO, you should never use H4, if there is no H3 etc. If it is your first (and highest level) section, H1 should be the correct choice. If it has a too huge font size, it's a problem of SO's CSS, not of a wrong heading level. Oct 7, 2021 at 5:22
  • 2
    Concerning sections in general: If there is only one (sub-)section, then there is basically no (sub-)section and no heading is needed. At least in science, it is considered a bad style to have a single (sub-)section. As the asker uses a single H1 with a single H2, I consider both useless. Oct 7, 2021 at 5:28
  • 2
    Isn't there a meta post about appropriate H levels? Starting point (the duplicate was (automatically) deleted) - "creating headings that skip levels or unnecessarily reset the levels is an accessibility concern" Oct 7, 2021 at 9:32
  • 2
    From an MSE post: "The <h1> tag should be used as a heading for a document, an article or a page." Oct 7, 2021 at 9:38
  • 1
    @PeterMortensen "the duplicate was (automatically) deleted" But not the duplicate notice, maybe it should be deleted too. Oct 7, 2021 at 9:38
  • 9
    I really dislike that they've put content in HTML comments, such as <!-- Something worth celebrating with all the other crap this year and last. Can't I have just one emoji? --> so you only know it's there if you look at the revision history or edit the post.
    – Thom A
    Oct 7, 2021 at 14:53
  • I'm now starting to wonder if I'm doing it wrong. For longer answers I do add H2, H3 and occasionally H4. They are only -- and obviously -- structural. Does my long answer from yesterday set off any warning bells? Oct 8, 2021 at 19:46
  • 1
    As for comments in the main thread promoting an answer: I will do this if there’s an exchange in the comments that has led to or is addressed by an answer (by me or others) as a way of type of sign post to help thread the discussion together. Outside of that, this sounds like a distraction. Useful answers should float to the top (of the default sort) by earning community validation, not attempts to advertise. Oct 9, 2021 at 17:00
  • 2
    @ScottSauyet I don't think there is any problem whatsoever with your use of formatting in that answer. You clearly were using it to structure the answer, not call attention to it. Oct 9, 2021 at 21:06
  • @Scott Sauyet: Isn't it (effectively) only 3 levels? That is, H1, H2, and H3. May 28, 2022 at 15:44
  • 1
    @Peter: I think that answer only used two levels, but they were (Markdown equivalents of) H2 and H3. I usually use those ones -- and occasionally H4 -- thinking of the Question and Answers as the equivalents of H1. I asked only because I was concerned that the discussion here was frowning on headers altogether, a concern not bourn our by the subsequent discussion. May 28, 2022 at 16:07

2 Answers 2

25

Your concerns are right, this is really excessive attention-grabbing.

I can understand a header announcing that there's a new solution as of some year when all the existing answers are years old (heck, I've done that myself at least once), because that "hey this solution is a relevant, modern one" can be useful information (at least until we get version-tagging for answers, and other such features...)

However, gratuitous use of emojis (including making the header-sized), misuse of formatting tools (e.g. block quotes) for added emphasis and "visual pop", etc. are, frankly, abuse of the formatting tools provided. Stack Overflow answers aren't blog posts or pop up advertisements... they should focus on the content, and formatting tools should serve to improve that content.

As to the actions to be taken here, such formatting should be edited out and, if a rollback war ensues, a flag for a moderator should be raised (I don't think we need a meta discussion for every single post that implements the equivalent of a giant, gaudy neon sign on a traditional business street). The responding moderator may decline and say bring it to Meta, though, in which case, bring it on, I suppose... that will just risk the Meta effect.

Luckily, it seems the author of the answer that prompted this question has already taken heed of the issue here (either of some action we can't see or by viewing this Meta post), and edited the answer themselves to remove nearly all of the distracting/"loud" formatting.

Regarding your follow-up questions:

As @jonrsharpe points out in the comments, this seems to be a recurring problem for this user in posting this answer across multiple (duplicate, off-topic) questions.

Duplicate answers on multiple posts are not allowed, and are worthy of a mod flag. Such cross-posted answers are routinely deleted with a mod comment left giving guidance on answering in one place and flagging/voting to close additional questions as duplicates, where appropriate, instead.

Are comments by a user on the main question attempting to promote their answer (as I just noticed was also done by this user for their answer) acceptable? Or should that be flagged for removal?

This one depends, in my opinion. Excessive commenting should be flagged, as well as vague comments that don't provide any objective context (e.g. "just check out this solution: <link to own answer>"), pretty much all the time.

If there's just a single comment that says something like ("there's now a native/official way to do this: <link to answer/own answer>") and there are multiple pages of answers... then I might leave it, but certainly wouldn't complain if someone else felt it should be flagged as NLN.

15

Headers should be used for structure only

It's an accessibility concern! I just added an answer to Is using 'header' markdown okay in answers? that discusses the appropriate use of headers and text formatting.

Reposted below in case the link breaks:

Keep accessibility in mind when formatting web content

Use formatting for its intended purpose. Please don't use it gratuitiously! Screen readers provide structure and verbal cues for users who can't see the larger text size, different font, etc.

Headers

Sighted user get visual cues to help them organize information on a webpage: font size, placement, bolding, color, etc. Users of screen readers rely on programmatic headers <h1> to <h6> (Markdown # to ######) to convey structure.

WCAG 2.1 has guidenlines on Using h1-h6 to identify headings

  1. Check that heading markup is used when content is a heading and the heading markup indicates the appropriate heading level for the content.
  2. Check that heading markup is not used when content is not a heading.

Point 1. above means that text should not be marked bold, italicized, etc., to convey content structure. Point 2. above means that headings should not be used to convey emphasis, mood, or any other text formatting.

Text formatting

Bold text indicates importance. Italics indicate emphasis in another voice or mood. Sighted users get different visual indicators for text formatting like these. Users of screen readers rely on programmatic text formatting for verbal cues of their special status.

The WCAG 2.1 has guidelines on Using semantic markup to mark emphasized or special text.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .