Skip to content
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

Closed
wants to merge 2 commits into from

Conversation

rnystrom
Copy link
Contributor

  • Clean up docs
    • Remove IGListSectionType and IGListCollectionView
  • Fix TV app example

#trivial

Issue fixed: #675

Checklist

  • All tests pass. Demo project builds and runs.

@@ -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.
Copy link
Contributor

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

@@ -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:`.
Copy link
Contributor

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.

Copy link
Contributor

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

Copy link
Contributor

@jessesquires jessesquires left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉

@facebook-github-bot
Copy link
Contributor

@rnystrom has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator.

@facebook-github-bot
Copy link
Contributor

@rnystrom updated the pull request - view changes - changes since last import

@facebook-github-bot
Copy link
Contributor

@rnystrom has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Clean up documentation after IGListSectionType is removed
4 participants