@ecodev/natural 56.0.1 → 56.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -12,7 +12,6 @@ type Key = NaturalAbstractModelService<unknown, any, any, any, unknown, any, unk
12
12
  * `id` should be the ID of the object that will be updated.
13
13
  */
14
14
  export declare class NaturalDebounceService {
15
- private readonly flusher;
16
15
  /**
17
16
  * Stores the debounced update function
18
17
  */
@@ -25,7 +24,15 @@ export declare class NaturalDebounceService {
25
24
  * keep the same debouncing timeline.
26
25
  */
27
26
  debounce<T>(key: Key, id: string, source: Observable<T>): Observable<T>;
28
- cancel(key: Key, id: string): void;
27
+ cancelOne(key: Key, id: string): void;
28
+ /**
29
+ * Immediately execute the pending update, if any.
30
+ *
31
+ * It should typically be called before resolving the object, to mutate it before re-fetching it from server.
32
+ *
33
+ * The returned observable will complete when the update completes, even if it errors.
34
+ */
35
+ flushOne(key: Key, id: string): Observable<void>;
29
36
  /**
30
37
  * Immediately execute all pending updates.
31
38
  *
@@ -34,6 +41,7 @@ export declare class NaturalDebounceService {
34
41
  * The returned observable will complete when all updates complete, even if some of them error.
35
42
  */
36
43
  flush(): Observable<void>;
44
+ private internalFlush;
37
45
  /**
38
46
  * Count of pending updates
39
47
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ecodev/natural",
3
- "version": "56.0.1",
3
+ "version": "56.0.2",
4
4
  "license": "MIT",
5
5
  "repository": "github:Ecodev/natural",
6
6
  "sideEffects": false,