reactjs / react.dev

The React documentation website
https://react.dev/
Creative Commons Attribution 4.0 International
11k stars 7.51k forks source link

[Bug]: Missing explanation #7069

Closed smith558 closed 1 month ago

smith558 commented 2 months ago

Summary

The paragraph in section https://react.dev/learn/you-might-not-need-an-effect#chains-of-computations states "There are two problems with this code.", but only addresses one problem and never gets to explain what the second problem was.

Page

https://react.dev/learn/you-might-not-need-an-effect#chains-of-computations

Details

No response

BartoszKlonowski commented 1 month ago

Hello @smith558, thanks for reporting! The second issue is actually written just below the paragraph with the first one, and it's starting with

Even if it weren’t slow, as your code evolves, you will run into cases where the “chain” you wrote doesn’t fit the new requirements.

I agree it would be more readable if started with "Second issue is that, even if (...)", etc.