DEV Community

Discussion on: Introduction to React.memo, useMemo and useCallback

Collapse
 
redraushan profile image
Raushan Sharma

Hi TrinhDinhHuy, well put buddy, it helped me to clear out a few doubts that I had.

Moreover, I guess there's a type in the following code:

const myReply = React.memo(() => decideWhatToSay (girlFriendWords), [girlFriendWords])

I feel, instead of React.memo, it should be React.useMemo.

Keep writing!

Collapse
 
dinhhuyams profile image
TrinhDinhHuy

Thank you! I updated it