A memory leak is a common problem in programming where a piece of code does not properly manage and deallocate memory after it stops running. This is especially undesirable in long-running apps where these even KBs of unreleased memory cumulate over time and result in significant degradation in performance. To tackle this problem, Microsoft has unveiled a new tool in its Edge browser, offering debugging capabilities to developers.
In a blog post, Microsoft has revealed that the Detached Elements tool in its Edge DevTools suite can empower developers to investigate Document Object Model (DOM) leaks. As the name suggests, it will show you a list of detached elements that you can investigate further.
It is important to note that detached elements are not inherently undesirable. Some applications like Twitter attach and detach elements on purpose when loading your feed. That said, having a list of detached elements ensures that developers can dive deeper into their own applications and fix problematic DOM leaks.
Microsoft has published a demo chat application with here so you can test Detached Elements via Edge. The company's blog post also contains extensive information about how you can investigate DOM leaks in this app as well as real-world applications further so do check it out here. The Detached Elements panel is available starting from Edge 97 and you can submit feedback about it to Microsoft via the feedback icon in the top-right of Edge DevTools.
2 Comments - Add comment