Only UICollectionView inside StoryBoard have UICollectionViewCell inside.
If use XIB, create a new XIB with CellName.xib, add CollectionViewCell to it, specify name of UICollectionView custom class. After that use registerNib.
Sample code: https://github.com/lequysang/TestCollectionViewWithXIB
More Related Contents:
- UICollectionView Self Sizing Cells with Auto Layout
- UICollectionView flowLayout not wrapping cells correctly
- Dynamic cell width of UICollectionView depending on label width
- UICollectionView’s cell disappearing
- UICollectionView adding image to a cell
- UICollectionView Set number of columns
- Auto Layout in UICollectionViewCell not working
- Why on Xcode 11, UICollectionViewCell changes size as soon as you scroll (I already set size in sizeForItem AtIndexPath:)?
- UICollectionView update a single cell
- Displaying images on another view controller when button is clicked
- Cell spacing in UICollectionView
- UICollectionView: must be initialized with a non-nil layout parameter
- How to create a centered UICollectionView like in Spotify’s Player
- UICollectionView reloadData not functioning properly in iOS 7
- In iOS 12, when does the UICollectionView layout cells, use autolayout in nib
- View with continuous scroll; both horizontal and vertical
- UICollectionView Decoration View
- UICollectionView header dynamic height using Auto Layout
- UICollectionView cell subviews do not resize
- EXC_BAD_INSTRUCTION When Passing UICollectionView Cell Data to Different ViewController
- UICollectionView – didDeselectItemAtIndexPath not called if cell is selected
- Specifying one Dimension of Cells in UICollectionView using Auto Layout
- UIButton in cell in collection view not receiving touch up inside event
- UIRefreshControl on UICollectionView only works if the collection fills the height of the container
- Aligning right to left on UICollectionView
- UIRefreshControl with UICollectionView in iOS7
- UICollectionView with paging – setting page width
- How to scroll to a particluar index in collection view in swift
- UICollectionView auto scroll to cell at IndexPath
- Warning: UICollectionViewFlowLayout has cached frame mismatch for index path ‘abc’