
Description
memory-leak-audit is an agent skill from the Microsoft VS Code repository, listed on skills.sh. It audits code for memory leaks and disposable-object problems, which the skill calls the most common bug category in VS Code. It encodes the patterns that prevent and fix leaks. The first rule is never to use raw onload, onclick or addEventListener handlers directly, and to use the project's addDisposableListener helper instead. Further checks cover objects created in methods that run repeatedly, model lifecycle events such as onWillDispose and onDidClose, and event subscriptions added in constructors or setup methods. The skill applies when reviewing code that registers listeners or DOM handlers, fixing reports of listener counts that grow over time, or preparing a change that adds subscriptions. A skill is a SKILL.md file of instructions that an AI agent loads when a task calls for it. It is free and open source, and the skills.sh listing shows all three security audits passing.…
Highlights
- DOM listener rules with addDisposableListener
- Repeated-call allocation checks
- Model lifecycle event checks
- Constructor subscription review
Ratings & Reviews
No ratings yet
Be the first to rate memory-leak-audit.
People also visit

coding-standards
Baseline cross-project coding conventions for naming, readability, immutability
memory-leak-audit FAQ
What does the memory-leak-audit skill do?
It reviews code for memory leaks and undisposed objects, using a step-by-step checklist of leak-prone patterns.
What is the first rule?
Do not attach raw DOM handlers directly. Use addDisposableListener so the listener is disposed correctly.
When should I use it?
When reviewing listeners or handlers, fixing leak reports, or adding subscriptions in constructors.
How do I install it?
Run: npx skills add https://github.com/microsoft/vscode --skill memory-leak-audit
Is it free?
Yes. It is free and open source.
Are there security findings?
The skills.sh listing shows Gen Agent Trust Hub, Socket and Snyk all passing.
What are the best memory-leak-audit alternatives?
Popular alternatives to memory-leak-audit include code-tour, oracle and code-review. See all memory-leak-audit alternatives








