Use Memo hook :

use memo hook is used to prevent the rendering in react function component .
In react class level component we can use should component update method or react -pure Component class extension to pravent a component from re-rendering . Use Memo will only recompute the memorized value when one of the dependencies has changed .
it is same as useEffect it has sideEffect it will re-render every time .
But in Use Memo don't have that side effect only when ever the dependency has changed then only it will render .


UseEffect & Use Memo Difference:
it will execute after return and render
It will execute with rendering .