Here's a list of resources I pulled together that explain what refactoring is, why it exists, what code smells are, and the mechanics of refactoring.
- What's a code smell?
- A farily exhaustive list of code smells
- A definition and theories of refactoring
- Martin Fowler's Refactoring is widely considered the bible of refactoring philosophy and methodology.
- And here's a very quick summary of the book.
- General Workflow
- Check out all of the
Related Articles
, especially Renaming a Symbol, Extracting Code into a Method, and Creating a Superclass - There must be keyboard shortuts for all of these but I couldn't find them in 10 seconds so you'll have to search!
- While we're at it, though, you should know these shortcuts and tips for working with XCode.
- And here's every shortcut known to Apple.
- Check out all of the
- How to replace a switch statement with polymorphism.
- Actually this guy's whole refactoring website looks pretty great at first glance.
- A seven part series on objects and refactoring:
- Because I heard you're doing a Nav Controller project.
This was a big help on refactoring my current NavControl app. Some of the stuff they consider "smells" are actually good practice in iOS but I'll read a bit more about those to see how do them more efficiently. I'll keep coming back to this as I complete the app. Thanks for posting!