solidjs / solidjs/solid-docs

Document untrack behavior with uninitialized async reads (NotReady propagation)

Offen Anfängerfreundlich
#1,635 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Dieses Issue hat noch niemand übernommen.

Vorherrschende Sprache
MDX
Sterne
292
Forks
361
Ø Merge
7 Std. 51 Min.
Gemergte PRs (30 T.)
1

Beschreibung

From solidjs/solid#3007 (reported by @mizulu).

The untrack reference page (https://v2.solidjs.com/reference/solid-js/reactivity/untrack) should document how untrack interacts with async reads in 2.0:

  • untrack stops dependency tracking — reads inside it do not subscribe the surrounding computation.
  • It does not opt out of async settlement. Reading an async source that is not yet ready inside untrack still throws NotReadyError, which propagates to the owning computation: the owner suspends (participates in Loading boundaries) and re-runs once the source first resolves.

In other words, untrack(() => getColor()) where getColor is a pending async memo will still cause the owner to re-run when getColor first settles — the read is untracked, but the not-ready suspension is part of async graph resolution, not tracking.

The page should spell out this distinction (tracking vs. settlement) and show the pattern for a genuinely non-suspending read of a possibly-pending source (e.g. checking readiness with isPending/latest as appropriate) so users aren't surprised that untrack alone doesn't provide a fallback-value escape hatch. A fallback-value overload for untrack was considered in solidjs/solid#3007 and rejected — the docs are the fix.

Beitragsleitfaden

Beitragsleitfaden öffnen

Erste Schritte

  1. Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
  3. Forke das Repository und arbeite in einem Branch.
  4. Öffne einen Pull Request, der die Issue-Nummer nennt.

Rechercherichtung

Beginne mit der im Issue verlinkten untrack-Referenzseite und prüfe das dort beschriebene Verhalten asynchroner Lesevorgänge zusammen mit dem Kontext von solidjs/solid#3007. Aktualisiere die Seite so, dass sie Dependency-Tracking von der NotReady-Abwicklung unterscheidet, die Suspendierung und den erneuten Lauf des Owners erklärt und eine tatsächlich nicht suspendierende Bereitschaftsprüfung mit isPending/latest zeigt.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
javascript
Bereich
documentation
Issue-Typ
Dokumentation
Schwierigkeit
2/5
Geschätzter Aufwand
1-3 Stunden
Aktivitätsstatus
Ruhig
Klarheit
Klar beschrieben
Anfängerfreundlichkeit
78/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.