Last active
March 12, 2021 08:01
-
-
Save jeandavid/25b47c8d44cc529742688b06d3ff6c80 to your computer and use it in GitHub Desktop.
Accessing Resources from Embedded Framework Bundle
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 class MyView { | |
let imageView = UIImageView() | |
func setImage() { | |
let frameworkBundle = Bundle(identifier: "com.myframework") | |
let image = UIImage(named: "my_image", in: frameworkBundle, with: nil) | |
imageView.image = image | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment