Last active
July 31, 2022 08:19
-
-
Save aryasurya21/a014fc6c844bdfc2b3dfb0cda891ca45 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public override func awakeFromNib() { | |
super.awakeFromNib() | |
inspirationProductCollectionView.dataSource = self | |
inspirationProductCollectionView.delegate = self | |
let bundle = Bundle(identifier: "com.aryasurya.Shared") | |
//we could also do | |
//let bundle = Bundle(for: Self.self) since we are accessing the NIB from its own module | |
inspirationProductCollectionView.register(UINib( | |
nibName: "InspirationItemCollectionViewCell", | |
bundle: bundle), | |
forCellWithReuseIdentifier: "InspirationItemCollectionViewCell" | |
) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment