fateriddle Posted November 7, 2018 Share Posted November 7, 2018 I'm coding using babylonjs + reactjs. And I suspect there's memory leak somewhere in the code as stuff gets laggy over time. So what's the 101 list that I should check? I've imported a few assets, then created instance of them, also I'm creating new mesh as bullet everytime user click shoot button. In componentWillUnmount, I dispose every asset, and that's all I did. Is there something missing? Quote Link to comment Share on other sites More sharing options...
Guest Posted November 7, 2018 Share Posted November 7, 2018 So you're using React The thing to do is to use the F12 memory profiler. Run your app, go to the profiler and capture a snapshot. Then do stuff and go to a state where you think you removed everything then do a second snapshot. You can then compare them and see which objects were created and not removed Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.