In the official docs of React it mentions –

If you’re familiar with React class lifecycle methods, you can think
of useEffect Hook as componentDidMount, componentDidUpdate, and
componentWillUnmount combined.

My question is – how can we use the componentWillMount() lifecyle method in a hook?

21 Answers
21

Leave a Reply

Your email address will not be published. Required fields are marked *