bunja 0.0.2 → 0.0.3
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/bunja.ts +2 -4
- package/package.json +1 -1
package/bunja.ts
CHANGED
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
|
|
3
3
|
disposePolyfill: {
|
|
4
|
-
|
|
5
|
-
S.dispose ??= Symbol.for("dispose");
|
|
6
|
-
S.asyncDispose ??= Symbol.for("asyncDispose");
|
|
4
|
+
(Symbol as any).dispose ??= Symbol("Symbol.dispose");
|
|
7
5
|
}
|
|
8
6
|
|
|
9
7
|
type Dep<T> = React.Context<T> | Bunja<T>;
|
|
@@ -105,7 +103,7 @@ class BunjaInstance<T> extends RefCounter {
|
|
|
105
103
|
}
|
|
106
104
|
[Symbol.dispose]() {
|
|
107
105
|
delete bunjas[this.biid];
|
|
108
|
-
|
|
106
|
+
this.value[Symbol.dispose]?.();
|
|
109
107
|
}
|
|
110
108
|
}
|
|
111
109
|
|