@esportsplus/reactivity 0.21.0 → 0.22.0

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.
package/build/system.js CHANGED
@@ -140,7 +140,7 @@ function recompute(computed, del) {
140
140
  depth++;
141
141
  version++;
142
142
  try {
143
- value = computed.fn.call(computed, onCleanup);
143
+ value = computed.fn(onCleanup);
144
144
  }
145
145
  catch (e) {
146
146
  ok = false;
package/build/types.d.ts CHANGED
@@ -5,7 +5,7 @@ interface Computed<T> {
5
5
  cleanup: VoidFunction | VoidFunction[] | null;
6
6
  deps: Link | null;
7
7
  depsTail: Link | null;
8
- fn: (this: Computed<unknown>, onCleanup?: (fn: VoidFunction) => typeof fn) => T;
8
+ fn: (onCleanup?: (fn: VoidFunction) => typeof fn) => T;
9
9
  height: number;
10
10
  nextHeap: Computed<unknown> | undefined;
11
11
  prevHeap: Computed<unknown>;
package/package.json CHANGED
@@ -16,7 +16,7 @@
16
16
  },
17
17
  "type": "module",
18
18
  "types": "build/index.d.ts",
19
- "version": "0.21.0",
19
+ "version": "0.22.0",
20
20
  "scripts": {
21
21
  "build": "tsc && tsc-alias",
22
22
  "-": "-"
package/src/system.ts CHANGED
@@ -211,7 +211,7 @@ function recompute<T>(computed: Computed<T>, del: boolean) {
211
211
  version++;
212
212
 
213
213
  try {
214
- value = computed.fn.call(computed, onCleanup);
214
+ value = computed.fn(onCleanup);
215
215
  }
216
216
  catch (e) {
217
217
  ok = false;
package/src/types.ts CHANGED
@@ -7,7 +7,7 @@ interface Computed<T> {
7
7
  cleanup: VoidFunction | VoidFunction[] | null;
8
8
  deps: Link | null;
9
9
  depsTail: Link | null;
10
- fn: (this: Computed<unknown>, onCleanup?: (fn: VoidFunction) => typeof fn) => T;
10
+ fn: (onCleanup?: (fn: VoidFunction) => typeof fn) => T;
11
11
  height: number;
12
12
  nextHeap: Computed<unknown> | undefined;
13
13
  prevHeap: Computed<unknown>;