-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove refs to IGListSectionType, fix TV app example #676
Conversation
@@ -4,7 +4,7 @@ This guide provides notes and details on best practices in using `IGListKit`, ge | |||
|
|||
## Best Practices | |||
|
|||
- We recommend adding an assert to check [`-isKindOfClass:`](https://developer.apple.com/reference/objectivec/1418956-nsobject/1418511-iskindofclass) on the object you receive in [`-didUpdateToObject:`](https://instagram.github.io/IGListKit/Protocols/IGListSectionType.html#/c:objc(pl)IGListSectionType(im)didUpdateToObject:) in your section controllers. | |||
- We recommend adding an assert to check [`-isKindOfClass:`](https://developer.apple.com/reference/objectivec/1418956-nsobject/1418511-iskindofclass) on the object you receive in [`-didUpdateToObject:`](https://github.com/Instagram/IGListKit/blob/master/Source/IGListSectionController.h#L63-L72) in your section controllers. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
once 3.0 is ready, let's re-gen docs and re-link to the docs page
Guides/Getting Started.md
Outdated
@@ -8,23 +8,29 @@ After installing `IGListKit`, creating a new list is easy. | |||
|
|||
### Creating a section controller | |||
|
|||
Creating a new section controller is simple. You subclass `IGListSectionController` and conform to the `IGListSectionType` protocol. Once you conform to `IGListSectionType`, the compiler will make sure you implement all of the required methods. | |||
Creating a new section controller is simple. All you have to do is subclass `IGListSectionController` and override at least `cellForItemAtIndex:` and `sizeForItemAtIndex:`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: remove "all you have to do", just "Sublcass..."
also -- we should list didUpdateToObject:
. and i really think this method should assert.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not 100% sure I agree with that Jesse, whilst the majority will override didUpdateToObject:
in the case of decoration views such as adverts or loading views that don't have an object necessarily bound to them I don't see the reason to have the method overridden
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉
@rnystrom has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator. |
@rnystrom updated the pull request - view changes - changes since last import |
@rnystrom has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator. |
IGListSectionType
andIGListCollectionView
#trivial
Issue fixed: #675
Checklist