Skip to main content

Rules overview

eslint-plugin-runtime-cleanup rules target runtime resource lifetimes that are easy to leak when allocation and teardown drift apart.

Rulesโ€‹

Rule authoring expectationsโ€‹

Runtime cleanup rules should be conservative:

  • report only resource allocation patterns with a clear cleanup obligation
  • avoid whole-file heuristics that create noisy false positives
  • use type information only when it materially improves precision
  • prefer suggestions over autofixes when cleanup placement is ambiguous
  • document the exact lifecycle pattern the rule expects

Presetsโ€‹

The preset pages describe the exported config keys and are ready for future rules: