Over at StackOverflow, we have syntax highlighting for code blocks. I just left an answer with code blocks that are using language hints, but I don't see any highlighting at all.

Here's a link to the meta question on StackOverflow.

If we don't use it here, can we implement it?

1 Answer 1


UX StackExchange doesn't use syntax highlighting, no.

UX is technology agnostic and doesn't really focus on the implementation side of things. We're not about how to do something, we're about what should be done. Once it's been decided what the best UX approach to take is then it's up to the poster to go and figure out how to do it (or venture over to StackOverflow if they get really stuck and have tried everything).

Syntax Highlighting also has a problem because it is another resource that needs to be called on pageload for every page. When the vast majority of posts don't include nor warrant any code that's an unnecessary impact to page weight and page load.

While some code may look a bit more readable with syntax highlighting it's never really wrong without it. especially as the only code we really get are small snippets of CSS / HTML attributes.

Not that it's definitely something that'll never happen, but I see it as unnecessary and a negative impact on the site rather than a positive one. Most of the time if a question includes code then it's been asked on the wrong site, or if an answer includes code then it's not an answer focussed on the User Experience but on the implementation (which in my opinion is what your answer has done - focussing on how to do it rather than what should happen in the given user experience situation - that question asks what should happen for that pattern when used on select boxes, something you didn't address).

  • I see what you are saying. With respect to my answer, his question was not, "...what should happen for that pattern when used on select boxes?" His question was, "...does anyone know whether there is any documentation that can provide information on how this pattern can be used with other form elements for example a select-box and not just text input elements?" So essentially, he was saying I like the pattern, but I want it to work on select boxes as well. How can I do that? So that's what I answered. Maybe the question and answer should be migrated to SO? Jan 16, 2014 at 0:34

You must log in to answer this question.

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