Skip to content

Instantly share code, notes, and snippets.

@amcdnl
Created September 19, 2012 16:32
Show Gist options
  • Save amcdnl/3750634 to your computer and use it in GitHub Desktop.
Save amcdnl/3750634 to your computer and use it in GitHub Desktop.
Inline vs. External Docs for your Code

Inline vs. External Docs for your Code

I'm pro external, heres why...

Pros of external

  • Make code messy
  • Not maintained well, example Bob adds a new argument but never updates the docs.
  • Often not useful, example: // returns monkey whereas if your actually writing docs you put more thought into it
  • Examples and usage code is easier to read
  • Often more like 'docs' instead of 'specs'

Cons of external

  • Harder to maintain since its not right in front of you when you are making changes
  • Code examples have to be explicit since code isn't right in front of you
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment