Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 |
Tags
- tableView
- joined()
- uikit
- uisearchbar
- 대문자소문자
- swift
- xib
- IOS
- suffix()
- 라이징캠프
- Info.plist
- GIT
- alamofire
- 클론코딩
- 알고리즘
- Autolayout
- Segue
- API
- replacesubrange()
- github
- 코드업 파이썬 기초 100제
- 코딩테스트
- String()
- prefix()
- 프로그래머스
- reduce()
- zip()
- MVC
- 싱글톤
- components()
Archives
- Today
- Total
목록uiimage (1)
Daeng iOS
[iOS/UIKit] url 로 image 지정하기
api 연결을 해서 이미지를 불러오는데 이미지 응답 형식이 string으로 되어있었다..! extension UIImageView{ func load(url: URL){ DispatchQueue.global().async{ [weak self] in if let data = try? Data(contentsOf: url){ if let image = UIImage(data: data){ DispatchQueue.main.async{ self?.image = image } } } } } } let url = URL(string: "url") imageView.load(url: url!) "url"에 이미지 url을 넣고, imageView에는 아울렛 변수를 넣어주면된다! https://www.youtube..
IOS/UIKit
2022. 10. 24. 01:22