Use Context to Manage Current User State - Introduction to React #8

Опубликовано: 06 Ноябрь 2022
на канале: NL Tech
3,704
71

The React Context API allows passing data through the component tree without passing it as a prop at every level. It’s frequently used for global state like the current logged in user, themes, and other application-wide preferences. In this video I’ll focus on one of the most common use cases for context – storing information about the current user.

Contents:
0:00 Introduction
0:30 Introducing the Example App
0:50 The Component Tree
1:04 The Problem: Prop Drilling
1:20 The Solution: Context
1:33 Creating a Context
1:49 Setting up the Context Provider
2:23 Using the Context as Consumer
3:02 Passing State with Context
4:15 Abstracting the Context State and Provider
4:45 Conclusion

Email: [email protected]
Twitter:   / nikelaz  
LinkedIn:   / nikola-lazarov  

#react #course


Смотрите видео Use Context to Manage Current User State - Introduction to React #8 онлайн без регистрации, длительностью часов минут секунд в хорошем качестве. Это видео добавил пользователь NL Tech 06 Ноябрь 2022, не забудьте поделиться им ссылкой с друзьями и знакомыми, на нашем сайте его посмотрели 3,704 раз и оно понравилось 71 людям.