You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thank you for the great project!!
When I tapped a collectionView, how can I get "indexPath.section"?
I could get indexPath.item but indexPath.section always returns "0".
To get the indexPath for a given UICollectionView you should rely on the UITableView delegate instead of the UICollectionView one, since you would have a UICollectionView for each UITableView section, and every collection is separated from the other one. You would have a UICollectionViewindexPath.section greather than "0" only in the case you would have two UICollectionView inside a given UITableView section
Thank you for the great project!!
When I tapped a collectionView, how can I get "indexPath.section"?
I could get indexPath.item but indexPath.section always returns "0".
func collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) { print(indexPath.section) print(indexPath.item) }
Thank you!
The text was updated successfully, but these errors were encountered: