I'd like to not import NSObject+IGListDiffable so that I'll have to adopt that protocol manually, so that i'll get compiler checks on the objects I use in the IGList.
Now I don't see any errors if by mistake I return an object that doesn't implement isEqual. or if they fallback to the generic NSObject implementation.
Can I import IGListKit without import the NSObject+IGListDiffable category using cocoapods?
I'd actually love to get this to work. We could remove #import <IGListKit/NSObject+IGListDiffable.h> from the umbrella header and document that it has to be imported manually (including in the Swift bridging header).
However w/ the Swift bridging header, all Swift NSObjects will auto conform, so that doesn't help. At least you can create a Swift class that conforms to IGListDiffable without inheriting from NSObject.
@jessesquires what do you think? I could experiment w/ it. Could fit this in for 2.0.0 esp since we changed the equality method to -isEqualToDiffableObject:, that'll go hand-in-hand I think.
We could remove
#import <IGListKit/NSObject+IGListDiffable.h>from the umbrella header...
I think we should definitely do this. Having all of this implicit conformance is too much "magic" IMO.
In the IGListDiffable docs, we should @note: that you can use NSObject+IGListDiffable.h.
Resolved in 316fbe2b8b2508b58a0f38387c3a343b9c37e282
Most helpful comment
I think we should definitely do this. Having all of this implicit conformance is too much "magic" IMO.
In the
IGListDiffabledocs, we should@note:that you can useNSObject+IGListDiffable.h.