Category:Needs Code Sample

From Kolmafia
Revision as of 01:44, 3 March 2010 by imported>StDoodle (Created page with 'Please do your part in helping to document ash functions! Pages in this category have been flagged as needing code samples; it would really help us out if you provided one. ==W…')
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Please do your part in helping to document ash functions!

Pages in this category have been flagged as needing code samples; it would really help us out if you provided one.

What makes a good code sample?

  • Clearly shows how to use the function in a typical manner (not in some jury-rigged I-guess-you-could-do-it-that-way... er... way).
  • Isn't overly complicated; if the function doesn't return aggregates or use them as parameters, try to avoid them in the sample, for example.
  • Ideally, the code sample would be useful in some way, shape or form; even if it just duplicates other functionality (if it does, mention it in the code as a comment).


I'm bad at coding, or don't feel up to it right now; is there another way I can help?

  • Yes! If you see a function page that needs a code sample & doesn't have one, edit the page to include the line "needscode=yes|".
    • Place the line inside the function template call, after "{{FunctionPage|"
    • Don't put it inside another template call; if in doubt, the line right after "{{FunctionPage|" is ok.
  • If you see a page that does have code samples, but they're unlear, too complicated, etc., you can add "improvecode=yes|"
    • Place this line the same way as for "needscode=yes|"