A podcast about web design and development.
…
continue reading
תוכן מסופק על ידי Frontend First, Sam Selikoff, and Ryan Toronto. כל תוכן הפודקאסטים כולל פרקים, גרפיקה ותיאורי פודקאסטים מועלים ומסופקים ישירות על ידי Frontend First, Sam Selikoff, and Ryan Toronto או שותף פלטפורמת הפודקאסט שלהם. אם אתה מאמין שמישהו משתמש ביצירה שלך המוגנת בזכויות יוצרים ללא רשותך, אתה יכול לעקוב אחר התהליך המתואר כאן https://he.player.fm/legal.
Player FM - אפליקציית פודקאסט
התחל במצב לא מקוון עם האפליקציה Player FM !
התחל במצב לא מקוון עם האפליקציה Player FM !
React Deep Dive: useOptimistic
MP3•בית הפרקים
Manage episode 400981458 series 1635850
תוכן מסופק על ידי Frontend First, Sam Selikoff, and Ryan Toronto. כל תוכן הפודקאסטים כולל פרקים, גרפיקה ותיאורי פודקאסטים מועלים ומסופקים ישירות על ידי Frontend First, Sam Selikoff, and Ryan Toronto או שותף פלטפורמת הפודקאסט שלהם. אם אתה מאמין שמישהו משתמש ביצירה שלך המוגנת בזכויות יוצרים ללא רשותך, אתה יכול לעקוב אחר התהליך המתואר כאן https://he.player.fm/legal.
Ryan and Sam discuss the purpose and usage of the useOptimistic() hook, a new experimental API from React.
Topics include:
- 0:00 - Intro
- 2:18 - Problem: RSCs require a server roundtrip before the UI can be updated
- 10:13 - Solution: useOptimistic() lets you merge ephemeral client-side state with server-side data so you can update the UI during a Server Action or Transition
- 14:03 - How useOptimistic() avoids the notion of identity by discarding the ephemeral state after the app settles
- 21:17 - How useOptimistic() lets you safely “fork” state that eventually syncs with the server
- 27:32 - Handling error states
- 29:26 - Differences between useOptimistic() and Remix fetchers
- 34:57 - How useOptimistic() lets you avoid managing a long-lived client-side cache
Links:
185 פרקים
MP3•בית הפרקים
Manage episode 400981458 series 1635850
תוכן מסופק על ידי Frontend First, Sam Selikoff, and Ryan Toronto. כל תוכן הפודקאסטים כולל פרקים, גרפיקה ותיאורי פודקאסטים מועלים ומסופקים ישירות על ידי Frontend First, Sam Selikoff, and Ryan Toronto או שותף פלטפורמת הפודקאסט שלהם. אם אתה מאמין שמישהו משתמש ביצירה שלך המוגנת בזכויות יוצרים ללא רשותך, אתה יכול לעקוב אחר התהליך המתואר כאן https://he.player.fm/legal.
Ryan and Sam discuss the purpose and usage of the useOptimistic() hook, a new experimental API from React.
Topics include:
- 0:00 - Intro
- 2:18 - Problem: RSCs require a server roundtrip before the UI can be updated
- 10:13 - Solution: useOptimistic() lets you merge ephemeral client-side state with server-side data so you can update the UI during a Server Action or Transition
- 14:03 - How useOptimistic() avoids the notion of identity by discarding the ephemeral state after the app settles
- 21:17 - How useOptimistic() lets you safely “fork” state that eventually syncs with the server
- 27:32 - Handling error states
- 29:26 - Differences between useOptimistic() and Remix fetchers
- 34:57 - How useOptimistic() lets you avoid managing a long-lived client-side cache
Links:
185 פרקים
כל הפרקים
×ברוכים הבאים אל Player FM!
Player FM סורק את האינטרנט עבור פודקאסטים באיכות גבוהה בשבילכם כדי שתהנו מהם כרגע. זה יישום הפודקאסט הטוב ביותר והוא עובד על אנדרואיד, iPhone ואינטרנט. הירשמו לסנכרון מנויים במכשירים שונים.