Whenever you're ready, walk me through how you'd approach this.
How do you manage component lifecycles, and why might you choose them over hooks in specific scenarios? Explain how React class lifecycle methods such as componentDidMount, componentDidUpdate, and componentWillUnmount compare with useEffect and related hooks. Keep the answer focused on React component behavior, side effects, cleanup, and practical trade-offs rather than implementation details of a specific application.