Fiber, the new React reconciliation algorithm, has the ability to start and stop rendering as needed for performance benefits. One of the trade-offs of this is that componentWillMount, the other lifecycle event where it might make sense to make an AJAX request, will be “non-deterministic”. What this means is that React may start calling componentWillMount at various times whenever it feels like it needs to. This would obviously be a bad formula for AJAX requests.You can’t guarantee the AJAX request won’t resolve before the component mounts. If it did, that would mean that you’d be trying to setState on an unmounted component, which not only won’t work, but React will yell at you for. Doing AJAX in componentDidMount will guarantee that there’s a component to update.SaveSavedRemoved 0 PreviousReact lifecycle methods NextWhat is Shallow Comparison from Official dox Related ArticlesAdded to wishlistRemoved from wishlist 0 How To Speed Up a WordPress (WP) Web SiteAdded to wishlistRemoved from wishlist 0 JavaScript Frameworks and Libraries ListAdded to wishlistRemoved from wishlist 0 Types of LinuxAdded to wishlistRemoved from wishlist 0 User Agents for Web Scraping