Skip to content

JSDoc @import not detecting use in @callback #58368

@turadg

Description

@turadg

🔎 Search Terms

jsdoc import @import callback lsp

🕗 Version & Regression Information

5.5 beta

  • I was unable to test this on prior versions because it's a new feature in 5.5. It was appearing in nightlies and I waited for the beta to confirm it's still there.

⏯ Playground Link

No response

💻 Code

/**
 * @import {Checker, Passable} from '@endo/pass-style';
 */

/**
 * @callback GetChecker
 * @param {Passable} payload
 * @returns {Checker}
 */

/**
 * @typedef {object} Misc
 * @property {Passable} passable
 */

🙁 Actual behavior

The Checker import is dim in an IDE and hovering says,

'Checker' is declared but never used.ts(6196)

🙂 Expected behavior

LSP detects that Checker is in the return of GetChecker.

Additional information about the issue

The use is detected in @typedef and @type. E.g. as with Passable in the example code.

Metadata

Metadata

Assignees

Labels

Fix AvailableA PR has been opened for this issueNeeds InvestigationThis issue needs a team member to investigate its status.

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions