Too Long; Didn't Read
Functional components can carry out life-cycle events without needing to be turned into a class based component. Less code is needed to be written to achieve the same goal. Manage componentWillMount with useEffect with a return function triggered when a component unmounts from the DOM. This is the only time it will fire on component render (componentWillMount) This means you can easily use and within functional components. This means that you can use both functions in the same useEffect function call.