Too Long; Didn't Read
React.memo is a higher-order component provided by React that will return a memoized version of the component that only changes if one of the props has changed. This helps to prevent unnecessary re-rendering of components and computations needed for component rendering. The method will memoize the component and does a shallow comparison of the rendered output then skips unnecessary rendering. This will prevent the recomputation during the render and the UI updates quickly. The parent component will import all these components and have a method to update the greetings count.