What is a key difference between the constructor and componentDidMount methods?
A key difference is that the constructor runs before the component is mounted to the DOM, while componentDidMount runs after the component has been mounted. This means componentDidMount has access to the DOM and can perform operations like measurements, subscriptions, or direct DOM manipulations that require the component to be rendered first.