This rule disallows emptyDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/aurelienbobenrieth/gadget/llms.txt
Use this file to discover all available pages before exploring further.
onSuccess exports in Gadget action files. An empty onSuccess function serves no purpose and should be removed to keep the code clean.
Rule Details
This rule checks foronSuccess exports that have an empty function body (no statements) and reports them as unnecessary.
Severity: Warning
Auto-fixable: Yes
Examples
Incorrect
Correct
Auto-fixes
The rule automatically removes the entire emptyonSuccess export:
Gadget does not require an
onSuccess export. If you have no post-processing work to do, simply omit the export entirely.When to Use
This rule is included in therecommended config. It helps keep action files clean by removing unnecessary boilerplate.