Conclusion

Let's conclude how contextType property solved a few of the nesting problems.

The contextType property does solve the nesting problem a little bit. However, when we discuss hooks in a later chapter, you’ll see how they offer a much better solution.


In the next chapter, we will learn about another important concept of React.memo.

Get hands-on with 1400+ tech skills courses.