[Suggestion]: Add Async React Hooks section to hooks
Nessuno ha ancora preso questa issue.
- Lingua principale
- JavaScript
- Stelle
- 11.8k
- Fork
- 7.9k
- Merge medio
- 1g 11h
- PR unite (30g)
- 11
Descrizione
Summary
Update the hooks page to include a section on Async React hooks useTransition, useActionState, and useOptimistic
Page
https://react.dev/reference/react/hooks
Details
The current hooks page has a very React 18 thinking of useTransition (in the Performance Hooks section), useActionState (in other hooks), and is missing the useOptimistic hook. I believe these hooks are better served by being placed in a single section to help spread the React 19 thinking about these hooks.
Proposed Async React Hooks section
Async React Hooks {/async-react-hooks/}
Async React lets you build responsive apps by running async work in Actions callbacks passed to startTransition or action props. State updates from useActionState and useOptimistic must run inside an Action.
useTransitionlets you mark state updates as non-blocking so the UI stays responsive while they run.useActionStatelets you update state from an Action, for form submissions or async reducers.useOptimisticlets you show a temporary UI state while an Action is running.
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Direzione di ricerca
Inizia dalla pagina React hooks collegata nell’issue e verifica come sono organizzate le sezioni esistenti relative ai Performance Hooks e agli altri hook. Aggiungi, come proposto, una sezione Async React Hooks che includa useTransition, useActionState e useOptimistic, quindi verifica che i collegamenti e la formulazione della pagina siano accurati.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- javascript, react
- Ambito
- documentation
- Tipo di issue
- Documentazione
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Stato di attività
- Ferma
- Chiarezza
- Specificata chiaramente
- Idoneità per principianti
- 55/100