I have been writing components in React.js recently. I have never had to use methods like componentWillMount
and componentDidMount
.
rend
In my project which is a dashboarding tool, I have used componentDidMount().
On home page previously saved dashboards appear on the sidebar. I make an ajax call within componentDidMount() of component rendering Homepage, so as to fetch list of dashboards asynchronously after the page has been rendered.