Check out React 18's useExternalStore hook with TypeScript and generics

preview_player
Показать описание


👉 VS Code theme and font? Night Wolf [black] and JETBrains Mono

0:00 Introduction
1:00 Project Recap
9:02 Typescript Setup
11:24 Converting The Store
13:24 Converting The Components
15:40 Removing Context
18:55 Moving useStore to the Store
21:19 Typescript Generics 101
26:30 Making useStore Generic
27:11 Making The Whole Store Generic
28:33 Deriving The Store Type
29:15 Outroduction

#react18 #useExternalStore
Рекомендации по теме
Комментарии
Автор

Pure gold. You are making TS so approachable...

Booyamakashi
Автор

Thank you very much Sir for such a golden content. Really appreciate the work you're doing! I feel motivated by watching your videos.

nparashar
Автор

Thank You very much for this info-tutorial. One request, using an external json object used as value in multi-step multi page form.

pareshsolanki
Автор

LOVELY!!! Great to see doing things in Typescript.

Question: when importing the 'type', do we have to do `import { type ValueStore } from ...`? Can't we directly do `import { ValueStore } from ...`?

farzadmf
Автор

Please give a video of nx nestjs and nextjs app deployed on vercel .its help for us.

mushfiqurtanim
Автор

How did you do this cool text highlighting in beginning? Is it a VS code plugin that can do this? 🙂

TypeScriptTV
Автор

Man can u react basic to advanced tutorial, your all content so much advanced level

brajagopalmukherjee
Автор

Can you create a tutorial series about developing a small web framework from scratch with Vite(something like Astro)

kasvith
Автор

{Sigh}, and I used to think "x = x + 1" would do it, for a counter on a web page ;(

lkd
Автор

This react shit going into infinity unnecessary! You need one year of time to just try every React Hook. If React continue to develop bullshit, will became as Angular. Every framework will die when developers cant keep track of it! This is easy solvable in plain react using context, but, look, another hook! I code in React almost 5 years, and this really starts to bothering me!

zlackbiro
visit shbcf.ru