how do you express in code that you want some state updates to be long-running and async, but others can interrupt them?
how do you express in code that you want some state updates to be long-running and async, but others can interrupt them?
2014: Class state
2016: Redux
2018: useState, useReducer, useContext
2020: React query
2021: Zustand for globals
2024: useOptimistic, useTransition, useFormStatus, useActionState, RSC
2025: Tanstack DB or sync engine (Zero, Electric, Convex)
2014: Class state
2016: Redux
2018: useState, useReducer, useContext
2020: React query
2021: Zustand for globals
2024: useOptimistic, useTransition, useFormStatus, useActionState, RSC
2025: Tanstack DB or sync engine (Zero, Electric, Convex)
aurorascharff.no/posts/buildi...
aurorascharff.no/posts/buildi...
Components handle async coordination and UI internally:
• Pending states via useTransition
• Optimistic updates via useOptimistic
Two examples with live demos ↓
aurorascharff.no/posts/building-design-components-with-action-props-using-async-react
Components handle async coordination and UI internally:
• Pending states via useTransition
• Optimistic updates via useOptimistic
Two examples with live demos ↓
aurorascharff.no/posts/building-design-components-with-action-props-using-async-react
https://zenn.dev/h_yokoyama/articles/react19-usetransition
https://zenn.dev/h_yokoyama/articles/react19-usetransition
It uses React's useOptimistic and useTransition hooks to create instant-feeling database updates.
Also experimenting with a single monospace font size and using "ch" and "rem" units for character-based UI spacing.
It uses React's useOptimistic and useTransition hooks to create instant-feeling database updates.
Also experimenting with a single monospace font size and using "ch" and "rem" units for character-based UI spacing.
startTransition + await のパターンがダメってなってるけど "useTransition – React" https://react.dev/reference/react/useTransition
startTransition + await のパターンがダメってなってるけど "useTransition – React" https://react.dev/reference/react/useTransition
react.dev/blog/2024/12...
#react #javascript #js #webdev
react.dev/blog/2024/12...
#react #javascript #js #webdev
I'm learning React JS & Next JS. Here's what I covered today:
✅ continued working on "The Wild Oasis" website
✅ build guest's reservation page
✅ deleting a reservation
✅ cache revalidation
✅ useTransition hook
#webdevelopment #100daysofcode
I'm learning React JS & Next JS. Here's what I covered today:
✅ continued working on "The Wild Oasis" website
✅ build guest's reservation page
✅ deleting a reservation
✅ cache revalidation
✅ useTransition hook
#webdevelopment #100daysofcode
https://zenn.dev/kiwichan101kg/articles/ef6992a45de2bd
https://zenn.dev/kiwichan101kg/articles/ef6992a45de2bd