Skip to content

Commit a0f755a

Browse files
committed
refactor: 코디네이터에서 캐싱하는 Store들은 Bindable 처리
1 parent 546a321 commit a0f755a

2 files changed

Lines changed: 5 additions & 4 deletions

File tree

Application/DevLogPresentation/Sources/PushNotification/PushNotificationListView.swift

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,16 +15,17 @@ struct PushNotificationListView: View {
1515
@ScaledMetric(relativeTo: .largeTitle) private var labelWidth = 34
1616
@State private var headerOffset: CGFloat = 0
1717
@State private var isScrollTrackingEnabled = false
18-
@State private var store: StoreOf<PushNotificationListFeature>
18+
@Bindable var store: StoreOf<PushNotificationListFeature>
1919
let coordinator: PushNotificationListViewCoordinator
2020
let isCompactLayout: Bool
21+
2122
init(
2223
coordinator: PushNotificationListViewCoordinator,
2324
isCompactLayout: Bool
2425
) {
2526
self.coordinator = coordinator
2627
self.isCompactLayout = isCompactLayout
27-
self._store = State(initialValue: coordinator.store)
28+
self.store = coordinator.store
2829
}
2930

3031
var body: some View {

Application/DevLogPresentation/Sources/Today/TodayView.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import DevLogCore
1111
import DevLogDomain
1212

1313
struct TodayView: View {
14-
@State private var store: StoreOf<TodayFeature>
14+
@Bindable var store: StoreOf<TodayFeature>
1515
let coordinator: TodayViewCoordinator
1616
let isCompactLayout: Bool
1717

@@ -21,7 +21,7 @@ struct TodayView: View {
2121
) {
2222
self.coordinator = coordinator
2323
self.isCompactLayout = isCompactLayout
24-
self._store = State(initialValue: coordinator.store)
24+
self.store = coordinator.store
2525
}
2626

2727
var body: some View {

0 commit comments

Comments
 (0)