memory-leak-audit
CommunityEliminate memory leaks in code.
Software Engineering#typescript#performance#debugging#javascript#memory leak#event listeners#disposable
Authormalwarebo
Version1.0.0
Installs0
System Documentation
What problem does it solve?
This Skill addresses the critical issue of memory leaks in code, which can degrade application performance and stability over time, particularly in complex JavaScript environments.
Core Features & Use Cases
- Event Listener Auditing: Ensures all DOM event listeners are properly managed using
addDisposableListener. - One-Time Event Handling: Utilizes
Event.once()for events that should only trigger a single action, preventing persistent listeners. - Resource Management: Guides the correct use of
MutableDisposableandDisposableStorefor managing disposables in repeated method calls and model lifecycles. - Test Validation: Integrates with test suites via
ensureNoDisposablesAreLeakedInTestSuite()for automated leak detection. - Use Case: When reviewing code that adds event listeners in a loop or within component lifecycles, this skill provides a checklist to ensure no listeners are left dangling, preventing gradual memory bloat.
Quick Start
Use the memory-leak-audit skill to review the provided code for potential memory leaks related to event listeners and disposable objects.
Dependency Matrix
Required Modules
None requiredComponents
references
💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: memory-leak-audit Download link: https://github.com/malwarebo/nyrve/archive/main.zip#memory-leak-audit Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 223,000+ vetted skills library on demand.