Skip to content

Instantly share code, notes, and snippets.

@AndyDangerous
Created October 7, 2014 19:05
Show Gist options
  • Save AndyDangerous/78f648f77389fad52949 to your computer and use it in GitHub Desktop.
Save AndyDangerous/78f648f77389fad52949 to your computer and use it in GitHub Desktop.
SRP Controllers
What's the job of a controller in Rails?
Web bullshit, duh.
Why do controllers tend to get complicated?
It's super-easy to put a ton of logic in them, it's also easy to engodden* them
What is the Single Reponsibility Principle about?
Making sure your things know what they're supposed to know, nothing more or less.
*to make godlike
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment