6

I'm wondering if it makes more sense to use code blocks in an answer to make it easier to read and help separate from the instruction to the reasoning etc.

As in

"This can be solved using method XYZ

Go to Sample > Word > 3

And then do process ABC"


The reason I'm asking, is because somebody mentioned to only use code-blocks for code.

So, I started doing this:

This can be solved using method XYZ

Go to Sample > Word > 3

And then do process ABC

(because without any variation it makes it more difficult to diffrentiate)

This can be solved using method XYZ

Go to Sample > Word > 3

And then do process ABC


However, I notice many people (myself included, up until recently) would use it for better formatting (It definitely makes it easier to read - I'm not sure if that's problematic, since it isn't actually code)


I'm looking for any input and opinions on this.

2
  • Aren't those quote blocks, not code blocks?
    – SilverWolf
    Dec 1, 2017 at 19:20
  • @seaturtle yes, I've placed in quote blocks, but I'm referring to the code blocks.
    – Welz
    Dec 1, 2017 at 19:37

1 Answer 1

10

No. I've done it myself but after frequenting another SE community learned that is has negative effects and is frowned upon.

Inline Code Spans should not be used for emphasis, right?

https://gaming.meta.stackexchange.com/questions/7437/using-code-ticks-for-technical-term-highlighting-considered-harmful

[Using backticks is] not just distracting, it's semantically wrong. Code formatting is semantic HTML to indicate to a parser that text is code. If we start lying to our parsers, we break tools built on HTML. Consider screen readers: if a visually impaired user configures their software to spell out code tags, or to have an easy keyboard shortcut with a macro called "jump to next code span/block and highlight" for easy copy-pasting, we are significantly disabling their ability to interact with the page. Further disabling, I should say.

You must log in to answer this question.

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