@@ -71,6 +71,7 @@ import ReactiveSwift
71
71
/// .tabItem { Text("Profile") }
72
72
/// }
73
73
/// }
74
+ /// }
74
75
/// ```
75
76
///
76
77
/// ### Thread safety
@@ -85,13 +86,14 @@ import ReactiveSwift
85
86
/// It is possible to make this process thread-safe by introducing locks or queues, but this
86
87
/// introduces new complications:
87
88
///
88
- /// * If done simply with `DispatchQueue.main.async` you will incur a thread hop even when you are
89
- /// already on the main thread. This can lead to unexpected behavior in UIKit and SwiftUI, where
90
- /// sometimes you are required to do work synchronously, such as in animation blocks.
89
+ /// * If done simply with `DispatchQueue.main.async` you will incur a thread hop even when you are
90
+ /// already on the main thread. This can lead to unexpected behavior in UIKit and SwiftUI, where
91
+ /// sometimes you are required to do work synchronously, such as in animation blocks.
92
+ ///
93
+ /// * It is possible to create a scheduler that performs its work immediately when on the main
94
+ /// thread and otherwise uses `DispatchQueue.main.async` (_e.g._, see Combine Schedulers'
95
+ /// [UIScheduler][uischeduler]).
91
96
///
92
- /// * It is possible to create a scheduler that performs its work immediately when on the main
93
- /// thread and otherwise uses `DispatchQueue.main.async` (e.g. see CombineScheduler's
94
- /// [UIScheduler](https://github.com/pointfreeco/combine-schedulers/blob/main/Sources/CombineSchedulers/UIScheduler.swift)).
95
97
/// This introduces a lot more complexity, and should probably not be adopted without having a very
96
98
/// good reason.
97
99
///
@@ -111,6 +113,8 @@ import ReactiveSwift
111
113
/// However, by leaving scheduling out of the ``Store`` we get to test these aspects of our effects
112
114
/// if we so desire, or we can ignore if we prefer. We have that flexibility.
113
115
///
116
+ /// [uischeduler]: https://github.com/pointfreeco/combine-schedulers/blob/main/Sources/CombineSchedulers/UIScheduler.swift
117
+ ///
114
118
/// #### Thread safety checks
115
119
///
116
120
/// The store performs some basic thread safety checks in order to help catch mistakes. Stores
0 commit comments