You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -118,3 +120,38 @@ public extension SideEffect {
118
120
.init(effectKind:.concurrentEffect(effects))
119
121
}
120
122
}
123
+
124
+
publicextensionSideEffect{
125
+
/// Turns an side effect into one that can be debounced.
126
+
///
127
+
/// debounce is an operator that plays only the last event in a sequence of SideEffects that have been issued for more than a certain time interval.
128
+
/// To turn an effect into a debounce-able one you must provide an identifier, which is used to determine which in-flight effect should be canceled in order to start a new effect.
129
+
///
130
+
/// - Parameters:
131
+
/// - id: The effect's identifier.
132
+
/// - duration: The duration you want to debounce for.
133
+
/// - clock: A clock conforming to the `Clock` protocol, used to measure the passing of time for the debounce duration.
0 commit comments