Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
Sam Chaudry
25,519 PointsApple Documentation
I was wondering if somebody just give me some tips on how to better understand apple documentation? What is the most important features and what to look out for etc....
1 Answer
Hayden Evans
15,399 PointsI flip between Apple documentation and Stack Overflow for reference but I'll give this question a stab. When I am working on a new iOS project one thing I like to do is expand the doc set to it's first level and look for particular capabilities that I will likely need in the app. When you are looking through these sections there are a few types of documents you will find. Here's how I approach them:
Guides Before actually digging into the code, it is good to read some of the "Guides" in the particular portions of the SDK you will be using in your app. The Guides provide a good overview of how particular sections of the SDK work, how they can be used and why you would use them. They can be used as a good introduction to the documentation that follows or as a refresher on how that particular technology works.
Reference How useful you find the reference sections depends on your understanding of Object Oriented Programming. The more you understand it, the more straight forward it will be. One of the first things you will see is a brief description/overview of certain classes that give a brief description of what that particular class does. I usually interpret the "Tasks" section of the documentation as properties I need to set or methods I need to use to configure the classes for appropriate use in the app. "Properties" is a good place to find the complete set of class variables that can be accessed and used in the application. The bits of code underneath these properties give you an example of how you would instantiate them in your code. You will also find property availability (for compatible SDKs) and the specific header files these properties are declared in so you know which headers to import to access these properties/methods. The instance method sections are structured in much the same way but provide parameters (inputs) and their types as well as return values and their types. You won't know right off the bat exactly which methods you will need to use but short descriptions under each property and instance method should give you an idea. It is good to skim through these little descriptions.
Sample Code Fairly straight forward, these are small demo apps written by Apple engineers to demonstrate how the SDK works. These are particularly helpful as they allow you to see a finished product with functionality that may be applicable to what you are doing. Depending on which bit of sample code you download, the commenting may be great or sparse however.
WWDC Videos While these videos do not go into too much depth they are usually fairly good to use as tutorials as they usually cover best practices of using different parts of the SDK and the minimum bits of code you need to implement certain technologies. I have found these particularly useful for the iOS 7 SDK as I am working on iBeacons at the moment and there isn't a whole lot of content written about it at the moment. These videos are what you should turn to right when new versions of iOS are released. Aside from the docs, they will likely be your only reference for a few months until the official release.
Tip: Use bookmarks within the documentation panel! This comes in handy when you have to go back and forth between different portions of your app that use different parts of the SDK.
Anyways, I hope that answers some of your questions and I hope you will find the documentation useful for some of the things I mentioned!