79292666

Date: 2024-12-18 22:34:36
Score: 1
Natty:
Report link

The @param tag only works at the block level, not inline. You need the @type tag.

function toggleButton(
    /**@type {HTMLButtonElement}*/ btnEl,
    /**@type {function():void=}*/ callbackFn
) { }

Here's what the Intellisense from vscode looke like

function toggleButton(btnEl: HTMLButtonElement, callbackFn: (() => void) | undefined): void

Reasons:
  • Probably link only (1):
  • Low length (0.5):
  • Has code block (-0.5):
Posted by: Jacob Stamm