UITableViewCell 을 만들때 이미 만들어진 셀이 없는 경우 아래의 코드를 이용해서 cell을 만들 수 있다. UITableViewCell(style: .subtitle, reuseIdentifier: "cell") 이때 style: _______ 부분을 보면 총 4가지의 옵션이 있는데 아래와 같다. 하나씩 어떤 모양인지 살펴보자 .default 더보기 func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { var cell = tableView.dequeueReusableCell(withIdentifier: "cell") if cell == n..
원문: https://www.hackingwithswift.com/swift/5.9/convenience-asyncthrowingstream-makestream Swift 5.9의 새로운 기능: AsyncStream과 AsyncThrowingStream의 makeStream 메소드 Swift 5.9에서는 SE-0388이라는 제안을 도입하여, AsyncStream과 AsyncThrowingStream에 makeStream() 메소드를 추가했다. 이 메소드는 스트림과 그 연속성을 동시에 반환하는 기능을 가지고 있다. 여기서 단어의 의미를 한번 짚고 넘어가자면, '스트림'이란 데이터를 순차적으로 처리하는 흐름 같은 걸 의미한다. 그리고 이 데이터들이 어떻게 생성되고 끝나는지를 관리하는 걸 '연속성'이라고 부른..
원문: https://www.hackingwithswift.com/swift/5.9/consume-operator Swift에서 Consume 연산자를 이해하고 사용하기 Swift의 새로운 기능인 consume 연산자는 값의 Lifetime을 명시적으로 끝내는데 사용되며, 이를 통해 개발자가 데이터가 전달될 때 발생하는 불필요한 retain/release 호출을 줄일 수 있다. 기본 사용법 struct User { var name: String } func createUser() { let newUser = User(name: "Anonymous") let userCopy = consume newUser // [✨] print(userCopy.name) } createUser() `// [✨]` 이 주석..
새 맥북에 Xcode 설치했더니 Git 설정이 안되어있다. 다운로드 받을게 많다 ..! 두근두근 차근차근 글로 남겨놔야징 1. Git 홈페이지 방문 https://git-scm.com/download/mac Git - Downloading Package Download for macOS There are several options for installing Git on macOS. Note that any non-source distributions are provided by third parties, and may not be up to date with the latest source release. Choose one of the following options for installing Git..
- Total
- Today
- Yesterday
- 이코테
- AsyncSwift Korea Seminar
- Swift Conference
- 자바
- CellStyle
- 싱글톤
- it seminar
- 꼼꼼한 재은 씨의 스위프트 문법편
- UITableViewCell
- 의존성
- 핵심내용
- SWIFT
- ios
- swift5.9
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
31 |