@solidjs/signals 2.0.0-beta.16 → 2.0.0-beta.18
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/README.md +4 -3
- package/dist/dev.js +421 -106
- package/dist/node.cjs +1908 -1642
- package/dist/prod.js +1719 -1454
- package/dist/types/affects.d.ts +47 -0
- package/dist/types/boundaries.d.ts +2 -2
- package/dist/types/core/async.d.ts +39 -2
- package/dist/types/core/constants.d.ts +8 -0
- package/dist/types/core/core.d.ts +9 -0
- package/dist/types/core/dev.d.ts +1 -1
- package/dist/types/core/error.d.ts +2 -0
- package/dist/types/core/index.d.ts +1 -1
- package/dist/types/core/invariants.d.ts +10 -0
- package/dist/types/core/scheduler.d.ts +43 -0
- package/dist/types/core/types.d.ts +22 -5
- package/dist/types/index.d.ts +1 -0
- package/dist/types/store/store.d.ts +32 -14
- package/dist/types-cjs/affects.d.cts +47 -0
- package/dist/types-cjs/boundaries.d.cts +2 -2
- package/dist/types-cjs/core/async.d.cts +39 -2
- package/dist/types-cjs/core/constants.d.cts +8 -0
- package/dist/types-cjs/core/core.d.cts +9 -0
- package/dist/types-cjs/core/dev.d.cts +1 -1
- package/dist/types-cjs/core/error.d.cts +2 -0
- package/dist/types-cjs/core/index.d.cts +1 -1
- package/dist/types-cjs/core/invariants.d.cts +10 -0
- package/dist/types-cjs/core/scheduler.d.cts +43 -0
- package/dist/types-cjs/core/types.d.cts +22 -5
- package/dist/types-cjs/index.d.cts +1 -0
- package/dist/types-cjs/store/store.d.cts +32 -14
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -108,7 +108,7 @@ const data = createMemo(async () => {
|
|
|
108
108
|
});
|
|
109
109
|
|
|
110
110
|
// Check async state for this read
|
|
111
|
-
isPending(data); // true while
|
|
111
|
+
isPending(data); // true while an unrevealed value change is in flight for this read
|
|
112
112
|
latest(data); // last resolved value; follows the not-ready path if no value has resolved yet
|
|
113
113
|
```
|
|
114
114
|
|
|
@@ -223,9 +223,10 @@ createRoot(dispose => {
|
|
|
223
223
|
| ------------------------ | ------------------------------------------------------------------ |
|
|
224
224
|
| `flush()` | Process all pending updates |
|
|
225
225
|
| `untrack(fn)` | Run `fn` without tracking dependencies |
|
|
226
|
-
| `isPending(accessor)` | Check if an
|
|
226
|
+
| `isPending(accessor)` | Check if an unrevealed value change is in flight for a read |
|
|
227
227
|
| `latest(accessor)` | Get the last resolved value, or follow not-ready if none exists |
|
|
228
|
-
| `refresh(accessor)` | Re-trigger an async computation
|
|
228
|
+
| `refresh(accessor)` | Re-trigger an async computation (a quiet re-ask — not pending) |
|
|
229
|
+
| `affects(target, key?)` | Declare that in-flight work will change the targeted data (reads pending until settle) |
|
|
229
230
|
| `resolve(fn)` | Returns a promise that resolves when a reactive expression settles |
|
|
230
231
|
| `mapArray(list, mapFn)` | Reactive array mapping with keyed reconciliation |
|
|
231
232
|
| `repeat(count, mapFn)` | Reactive repeat based on a reactive count |
|