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 | 31 |
Tags
- RxKotlin
- Koin
- PagingLib
- Observable
- node.js
- Kotlin
- Android 13
- Animation
- google play
- SwiftUI Tutorial
- node
- 인앱결제
- 동영상
- SWIFTUI
- mysql
- junit
- Android
- MediaPlayer
- MediaSession
- 테스트 자동화
- paging
- databinding
- mvvm
- php
- MotionLayout
- rx
- Reactive
- android13
- list
- GCP
Archives
- Today
- Total
봄날은 갔다. 이제 그 정신으로 공부하자
ViewController 호출 본문
너무 android쪽 글만 쓰는 것 같아 이제 짧게나마 다른 분야에 대해서도 글을 작성해볼까 합니다.
우선 iOS부터...
ViewController 호출
자신이 속한 storyBoard에 포함된 ViewController를 호출하는 경우,
guard let myDetailVC = self.storyboard?.instantiateViewController(withIdentifier: "MyDetailController") else { return }
myDetailVC.modalPresentationStyle = .fullScreen
self.present(myDetailVC, animated: true, completion: nil)
다른 storyBoard에 포함된 ViewController를 호출하는 경우,
let settingStoryBoard = UIStoryboard(name: "SettingController", bundle: nil)
guard let myProfileVC = settingStoryBoard.instantiateViewController(withIdentifier: "ProfileViewController") as? ProfileViewController else { return }
myProfileVC.modalPresentationStyle = .fullScreen
self.present(myProfileVC, animated: true, completion: nil)
'iOS Tip' 카테고리의 다른 글
| 3-1. SwiftUI Tutorial - List filter & sort (1) | 2022.03.08 |
|---|---|
| 2-2. SwiftUI Tutorial - List (2) | 2022.03.04 |
| 2-1. SwiftUI Tutorial - Hashable, Codable, Identifiable (0) | 2022.03.01 |
| 1. SwiftUI Tutorial - @main, @State, @Binding (0) | 2022.02.25 |
| swift optional 제거 방법 (1) | 2022.02.22 |
Comments