Skip to content

New rule: disallow combining multiple @typedef / @callback tags in one comment #1445

@remcohaszing

Description

@remcohaszing

Motivation

With TypeScript types in JSDoc, it’s possible to combine multiple @typedef or @callback tags. In some cases however, this causes weird hard to debug conflicts. This is demonstrated in this TypeScript playground.

Current behavior

There is no rule.

Desired behavior

It would be good if there’s a rule that disallows combining multiple @callback or @typedef tags in one JSDoc block.

Alternatives considered

At first it seemed like a good idea to have a more configurable rule to disallow duplicate tags. However, the combination of @callback and @typedef is also problematic.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions