I am writing a custom Collection View Layout in swift and xcode 8. I tried implementing the custom collection view layout attributes with the following function
override class func layoutAttributesClass() -> AnyClass {
return CircularCollectionViewLayoutAttributes.self
}
But I get error 'Method does not override any method from its superclass'. Any help is much appreciated.
You should use var
instead of func in Swift 3:
override class var layoutAttributesClass: AnyClass {
// ...
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With