Skip to main content
RecommendedStrictAuto-fixableScope
warnerrortrueGadget action files
Related Gadget documentation: Gadget docs
What the linter reports:
onSuccess return values are ignored. Use return; or remove it.

Examples

api/models/widget/actions/create.ts
export const onSuccess: ActionOnSuccess = async ({ record }) => {
  await notify(record);
  // return values in onSuccess are silently ignored by Gadget
  return someVariable;
};
Last modified on March 10, 2026