์ผ | ์ | ํ | ์ | ๋ชฉ | ๊ธ | ํ |
---|---|---|---|---|---|---|
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 |
- Lv2
- ๋ฐฑ์ค
- Xcode
- BFS
- Swfit
- realm
- Flutter
- Kuring
- SnapKit
- node.js
- UIKit
- raywenderlich
- arkit
- tableView
- combine
- rxcocoa
- SwiftUI
- TCA
- ํจ์คํธ์บ ํผ์ค
- XCTest
- RxSwift
- CollectionView
- visionOS
- BOJ
- ios
- MVVM
- ํ๋ก๊ทธ๋๋จธ์ค
- swift
- reactorkit
- designpattern
- Today
- Total
๋ชฉ๋กeffect (4)
lgvv98
[TCA] Effect #6 (WebSocket) ๋ชฉ์ฐจ - ์ด๋ฒ์ ํ ์ค์ต์ ๋ํ ์ค๋ช - ์น์์ผ ๊ฐ๋ ์ ๋ํด์ ์ค๋ช ์ ์๋ต - ๋์ ์ด์ ์์ ์์์ ์น์์ผ๊ณผ ์ฐ๊ด์ง์ด ์๊ฐํด๋ณด๊ธฐ - TCA WebScoket ์์ # ์ด๋ฒ์ ํ ์ค์ต์ ๋ํ ์ค๋ช URLsession์ ์น์์ผ์ฉ API๋ฅผ ์ํ ๊ฐ๋จํ Wrapper๋ฅผ ๋ง๋ค์ด ์์ผ ์๋ฒ์ ์ ์ํ์ฌ ํ ์คํธํ ํ ๋ฉ์์ง๋ฅผ ์ ์ก ํ ์์ผ ์๋ฒ๋ ์ฆ์ ๋ฉ์์ง๋ฅผ ํด๋ผ์ด์ธํธ์๊ฒ ํ์ . - ๋์ ์ด์ ์์ ์์์ ์น์์ผ๊ณผ ์ฐ๊ด์ง์ด ์๊ฐํด๋ณด๊ธฐ ๋ด๊ฐ ๊ฐ๋ฐ์ ์ฒ์ ๊ณต๋ถํ ๋น์์๋ ์น์์ผ์ ์ด๋ ๊ฒ ๋ง์ด ๋ค๋ฃจ๋ฆฌ๋ผ๊ณ ์๊ฐํ์ง ๋ชปํ๋๋ฐ, ๋ฉ์ธ์ผ๋ก ์ฌ์ฉํ๊ณ ์์. ์ฒ์ ์ด๋ก ์ด ์๋ ์น์์ผ์ ์ ํ๊ฒ ๋ ๊ฒ์ Kuringํ๋ก์ ํธ์์ ๊ฒ์ํํธ๋ฅผ ๊ตฌํํ๋ฉด์ ์ฒ์ ์๊ฒ ๋์๋๋ฐ, ๋น์์๋ StarS..
[TCA] Effect #4 (Refreshable) ๋ชฉ์ฐจ - Refreshable์ ๋ํ - Refreshable์ ์ฌ์ฉํ๋ ์์ # Refreshable์ ๋ํ ์ด๋ฒ์๋ List๋ฅผ ๋ฆฌํ๋ ์ ํ๋ ๋ฐฉ๋ฒ์ ๋ํด์ ์์๋ณด์ ์ด๋ฒ์๋ ๋ฒํผ์ ํด๋ฆญํด์ API ์ฝํ๋๊ฒ ์๋๋ผ ๋ฆฌํ๋ ์๋ฅผ ํตํด API๋ฅผ ์ฝ ํ ์์ ์ด๋ค. ํน์ด์ ์ผ๋ก๋ viewStore.send(..., animation: ) ์ผ๋ก animation์ ๊ฑด๋ค์ฃผ์ด ๋ณผ ์์ ! # Refreshable์ ์ฌ์ฉํ๋ ์์ // MARK: - Feature domain struct Refreshable: Reducer { struct State: Equatable { var count = 0 var fact: String? } enum Action: Equata..
[TCA] Effect #1 (Cancellation) ๋ชฉ์ฐจ - ํด๋น ์์ ์ ๊ด๋ จํ ์ค๋ช - ํด๋น ์์ ์ฝ๋ # ํด๋น ์์ ์ ๊ด๋ จํ ์ค๋ช This screen demonstrates how one can cancel in-flight effects in the Composable Architecture. Use the stepper to count to a number, and then tap the "Number fact" button to fetch a random fact about that number using an API. While the API request is in-flight, you can tap "Cancel" to cancel the effect and prevent it fro..
[TCA] Effect #1 (Basics) ๋ชฉ์ฐจ - Effect๋? - Effect Basic ์์ ์ดํด๋ณด๊ธฐ - Effect๋? TCA๋ก ๋ง๋ค์ด์ง ๊ธฐ๋ฅ์ Side Effect์ ๋์ ํ ์ ์์. Side Effect๋ ์ธ๋ถ์์ ์ํ๋์ด์ผ ํ๋ ์์ ๋ค๋ก API ์์ฒญ, HTTP๋ฅผ ํตํด ์ธ๋ถ ์๋น์ค๋ฅผ ์ฌ์ฉํ๋ ๋ฑ ๋ถํ์คํ๋ฉฐ ๋ณต์กํ๊ธฐ๋ ํจ. - ์์ด ์ฉ์ด ์ ๋ฆฌ NB: nota bene๋ผ๋ ๋ผํด์ด๋ก ์ฃผ์, ์ ์๋ผ๋ ์๋ฏธ - Effect Basic ์์ ์ดํด๋ณด๊ธฐ import ComposableArchitecture import SwiftUI // MARK: - Feature domain struct EffectsBasics: Reducer { struct State: Equatable { var count = 0..