Closed squandev closed 2 years ago
At the moment, the only solution I have found is to call the function in DispatchQueue.main.async
It happens because in viewDidLoad
views are not constrainted yet, and skeleton also animates constraint changes, Try view.layoutIfNeeded()
before showing skeleton, I had a same problem in a UITableViewCell
and
func collectionSkeletonView(_ skeletonView: UITableView, prepareCellForSkeleton cell: UITableViewCell, at indexPath: IndexPath) {
cell.layoutIfNeeded()
}
this fixed the issue.
Hi guys, this issue has been fixed in the latest version (1.29.1).
Feel free to reopen a new issue if you find another issue 🙂
Description
When a view controller appears, in which subviews are specified using constraints, the skeleton's appearance animation is visible
What type of issue is this?
Requirements
SkeletonView Environment:
SkeletonView version: 1.25.1 Xcode version: 12.2 Swift version: 5.3
Attachments:
https://user-images.githubusercontent.com/40371778/135757200-8c9ce9d6-af05-40b6-91a7-1c78b185300f.mov