ReactJS : Working with the Context API, With Class Based Components

preview_player
Показать описание
In this tutorial, we are going to be talking about the context API, which allows us to provide a global state. By providing this global state, this prevents the need of prop drilling.
Рекомендации по теме
Комментарии
Автор

Thanks. I knew how to do that with hooks and function components, but I haven't ever gotten to learn the class's way. Very useful and clear.

faris.abuali
Автор

Thanks. I knew how to do that with hooks and function components, but havent ever gotten to learn the classes way. Very useful and clear.

irriet
Автор

Thanks a lot, i just worked on legacy codebase, it really helps me to understand how to use context in class component.

beluck
Автор

Thank you so much for this video. Most videos out there explain it using functional components. 👍

danielginting
Автор

First approach of consuming was really useful to me! Thanks!

ricardodanielanaya
Автор

Awesome. Please make a video on hooks with context API

rangabharath
Автор

Thank you for the very good explanation on this.

lahirudx
Автор

very good series please make more videos

nagendrapp
Автор

Hi, thanks for a video, it really helped me. But I have a qustion. How to fetch data from API using context? Can I just put componentDidMount and add fetch() to FileContext.js and then set state? Is it correct way?

pavel
Автор

wow really great !! make a video on hooks with context API

vickyvignesh
Автор

Hi Sir, Thank you are your great Video here, Please is there any way i can setstate with the global variable I pass on using context api in componentDidMount, I can use destructuring in and use inside the render but i want to save it outside render and perform Crud operation

cashcold
Автор

How to change username to other then Bob?

somerandomchannel
Автор

HI Thank you very much for this video, its help me to lifting up state(state management) but i have very important question which i faced, only render method call when we call the login or logout function, not any other method like constructor or componentwillmount or etc, so we can say that we can't keep child component own state because we can't update child state by contextApi state (because we only have one place where we can use setState method which is render method, and if you put it in render method, then it would be recursive to infinite loop ) because every time state change render call and again and again this happen

or we keep child state but can't update by context api state

please answer if any one who know the answer

gtrjtgjr
Автор

Hey, there more videos on class based components please. Functional components is really overrated.

whoman
join shbcf.ru