Suppose I am answering a question which requires a long answer or the question contains several smaller question not sufficiently good enough to be asked separately then it will be good to give a content page at first.

How can I do it here? A simple example would be nice.

  • Do you mean the "Contents" table in each Wikipedia article that has links to sections/subsections? – Mat Oct 6 '14 at 16:20
  • yes, which i can use to navigate inside the same page – k4vin Oct 6 '14 at 16:39
  • Related: meta.stackexchange.com/questions/37894/… (having this would help writing answer with "sub answers" inside) – Shadow The Princess Wizard Oct 6 '14 at 19:11

There is no feature directly comparable to the auto-generated Tables of Contents found on, for example, Wikipedia.

Here are some examples of ways in which folks work around this:

  1. ToC in the question, links to separate questions works well for extremely broad topics that are best separated into distinct, specific questions.

  2. ToC in the question, links to answers below works well for deceptively-broad topics that may have different answers depending on the context / specific needs of the asker.

  3. No explicit ToC, just links to related topics where they're relevant works well for answers that are self-contained but touch on related topics that would require a full answer (or multiple answers) to explain in detail.

  4. No explicit ToC, just reference sections by name where they're relevant works well for relatively short answers where background information is broken off to avoid distracting from the core answer.

All of these are quite rare; most answers - even long, detailed answers - do not need to break up the text in the same way that an encyclopedia article might, as they remain focused on solving a specific problem rather than attempting to exhaustively document a topic. Of the four, #3 is probably the most common, and isn't limited to referencing only Stack Overflow questions; lists of articles and documentation on external sites can be valuable additions to many answers where including such information inline would be a distraction.

Note also that many questions that would benefit from such techniques border on being "too broad" and would benefit from being broken up into smaller, more specific questions. Exceptions tend to be those "deceptively simple" questions that get asked a lot in various forms, where the value of having a comprehensive answer (or set of answer) trumps the cost of creating such comprehensive answers.

You must log in to answer this question.

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